The archbishop of Canterbury has risked angering the Zimbabwean president, Robert Mugabe, ahead of a crucial meeting with him, by attacking the country's lawlessness and comparing it with the "greed of colonialists and imperalists".

In a brave and possibly career-defining appearance at Harare's national stadium, Rowan Williams told a crowd of more than 15,000 that it was tragic that so many lived in daily fear of attack if they failed to comply "with what the powerful require of them".

His sermon, which frequently drew applause and cheers, comes as a devastating split in Zimbabwe's Anglican church wreaks increasing havoc on parishioners and clergy. A power struggle between the Mugabe-supporting, excommunicated bishop of Harare, Nolbert Kunonga, and his replacement, Chad Gandiya, has resulted in Anglicans being arrested, beaten and locked out of churches. Police loyal to Mugabe have helped evict people from buildings.

Williams praised Anglicans for their "patience, generosity and endurance" in the face of "injustice and arrogance" and said they did not have to live in "terror, in bloodshed".

He told them: "You know very well what it means to have doors locked in your faces by those who claim the name of Christians and Anglicans. You know how those who, by their greed and violence have refused the grace of God, try to silence your worship and frustrate your witness in the churches and schools and hospitals of this country.

"But you know that the will of God to invite people to his feast [in heaven] is so strong it can triumph even over these mindless and godless assaults."

Williams's reception was more fitting of a rock star than an archbishop, with whistles and ululations erupting as he arrived.

The spectacle followed weeks of headlines surrounding the archbishop's two-day visit to Zimbabwe and his requested meeting with Mugabe to discuss the hostility and violence meted out to Anglicans.

Under a grey metal roof, Williams said it was Africa's natural wealth that provoked the greed of colonialists and imperialists. It had become a curse, he said, as people were killed and communities destroyed "in the fight for diamonds that will forever be marked with the blood of the innocent".

"For a long period in this country, an anxious ruling class clung on to the power they had seized at the expense of the indigenous people and ignored their rights and their hopes for dignity and political freedom.

"How tragic that this should be replaced by another kind of lawlessness, where so many live in daily fear of attack if they fail to comply with what the powerful require of them."

In spite of his forthright words, Williams has sought to downplay the Zimbabwean leg of his central African tour by emphasising its spiritual nature.

He told reporters gathered at Malawi's Blantyre airport: "This is a pastoral visit at the invitation of my bishop brothers, but of course I shall be raising with President Mugabe the issue about the harassment and persecution of our church in Zimbabwe. What difference that will make is in God's hands, but I want to put that on the table."

Mugabe's office has yet to confirm whether there will be a meeting. A presidential spokesman, however, told the state-run Sunday Mail newspaper that Mugabe would challenge Williams about homosexuality and sanctions if the two men were to speak.

George Charamba said: "Fundamentally, he would want to know why the church of the British state, the Anglican church, has remained so loudly silent while the people of Zimbabwe, and these people include Anglicans, are suffering from the illegal sanctions.

"The second issue that the president wants this man of God to clarify is why his Anglican church thinks homosexuality is good for us and why it should be prescribed for us. He thinks the archbishop will be polite enough to point to him that portion of the Great Book [that] sanctions homosexuality and sanctions sanctions."

The breakaway bishop Kunonga and his supporters protested against Williams' visit outside Harare's main cathedral, saying it was a "demonstration against homosexuality".

But there was far greater support for Williams. Hundreds of people were sitting on the stadium's concrete terraces hours before he was due to take to the stage, itself decked out with white chairs bearing blue ribbons, lit candles, a cross and a podium. The hundreds soon swelled to thousands and a party atmosphere developed. The stadium still bears the traces of its former life as a venue for basketball matches: old scoreboards, decrepit press boxes and a sign urging sports fans to "please remain seated during play".

Warm-up acts, more often seen in television studios or at concerts than in the run-up to a church sermon, entertained the crowds by singing, dancing and shaking maracas.

Esther Murazi, a 40-year-old vendor, wore a neckscarf with the words "Archbishop of Canterbury's Visit, October 2011, Harare, Zimbabwe" printed on it. She told the Guardian: "It's a big day for Zimbabwe. I've come to pray for my family and for my life."

Others also shared the sense of hope and longing inspired by Williams – who seldom arouses such sentiment back home – and the feeling that his visit could transform their lives.

Innocent Richards, a 39-year-old quantity surveyor, said: "He's the head of the church. Very, very special. We regard him as a leader. He's very brave coming to Zimbabwe in view of what's happening with the Anglican church. Some of us don't have anywhere to go. We hold the services under trees because all the properties have been taken. I think he's here to resolve some of these issues regarding the running of the church."

But the issue of homosexuality, so divisive in the Anglican Communion for decades, played on the minds of some.

Edgar Munatsi, 22, a medical student and secretary general of the Student Christian Movement Zimbabwe, said: "The people of Zimbabwe need solidarity from the UK. But people need clarity on the issue of homosexuality and he should have given it."