Pope Francis ventured into a volatile Muslim neighborhood of Central African Republic's capital on Monday to bring his message of reconciliation to the city's main mosque, insisting that Christians and Muslims have long lived peacefully together here and that religion can never justify violence.

Under heavy security, Francis crossed into the PK5 neighborhood where Bangui's Muslims have been unable to leave for months because of the armed Christian militia fighters who surround its perimeter. The pope traveled in his open-air vehicle through the neighborhood despite the security risks though armed U.N. peacekeepers stood guard in the minarets of the mosque.

The pope’s visit immediately ushered in a greater sense of freedom to the beleaguered area. In what had been a no-man’s land separating the Muslim enclave from the rest of the city only the day before, thousands crossed over into the area chanting “war is over” in the local Sango language after the pope’s departure.

Francis had insisted on coming to the PK5 neighborhood to appeal for peace in a country where two years of Christian-Muslim violence has divided the capital and forced nearly 1 million people to flee their homes. The once vibrant markets of PK5 have now been largely shuttered and many of the Muslim-owned businesses stand in ruins.

About 200 men seated inside the mosque welcomed Francis, who sat on a sofa. In comments to the chief imam, Francis insisted that Muslims and Christians are brothers and must behave as such.

“Christians and Muslims and members of traditional religions have lived peacefully for many years,” he said. “Together, we say no to hatred, to vengeance and violence, especially that committed in the name of a religion or God.”

The chief imam at the mosque, Tidiani Moussa Naibi, thanked Francis for his visit, which he said was “a symbol which we all understand.”

Pope Francis removed his shoes, bowed his head and stood silently at the mihrab, or area of the mosque that faces the holy Muslim city of Mecca.

The pope’s visit to the mosque marked the highlight of his three-nation African tour, with previous stops in Kenya and Uganda. He has a final Mass in Bangui's sports stadium later Monday before returning to Rome.

Central African Republic descended into conflict in 2013 when Muslim rebels overthrew the Christian president. That ushered in a brutal reign. When the rebel leader left power the following year, a swift and horrific backlash against Muslim civilians ensued.

Throughout the early months of 2014, mobs attacked Muslims in the streets, even decapitating and dismembering them and setting their corpses ablaze. Tens of thousands of Muslim civilians fled to neighboring Chad and Cameroon. Today, the capital that once had 122,000 Muslims has only around 15,000, according to Human Rights Watch.

Francis urged the international community to not view the country as doomed to a cycle of violence, saying the current conflict is a moment in time _ “a painful moment, a regrettable moment, but just a moment.”

“Yes, I confirm, Christians and Muslims of this country are condemned to live together and love one another,” he said.

Before the fighting drove away many Muslims, Central African Republic was 37 percent Catholic and about 15 percent Muslim, with traditional faiths and Protestants making up the rest, Vatican figures show.

While the two opposing militias are identified by their religious affiliation, Muslim and Catholic leaders disavow the perpetrators of violence.

The conflict did not begin over religious ideology but rather found its roots in a bid for political power. Muslim rebels from a number of groups in the north united in a bid to oust the president of a decade, citing grievances he had failed to follow through on promises and had neglected their part of the country.

The anti-Balaka Christian militia then arose after the Muslim rebels took power and committed atrocities against Christians. As the conflict surged, the Christian militias began targeting symbols of Islam, destroying mosques and attacking civilians who wore traditional Islamic clothing. Economic resentment also fueled the violence. The Muslim community was made up of prosperous merchants. As soon as the Muslims fled, their shops were looted and destroyed. In some cases, anti-Balaka even spray-painted their names on the homes of departing Muslims to claim them.

Francis reminded the Muslims in the central mosque that the origins of the conflict wasn't religious and urged them to put their own interests aside.

“We must remain united to prevent any action from either side that disfigures the face of God or has at its base the goal of defending particular interests at the expense of the common good,” he said.

Francis also praised the courage of those who risked their lives to shelter members of the other faith.

The Catholic Church, for example, played a pivotal role in protecting Muslims during the height of the crisis last year, sheltering nearly 1,000 people at a time on the grounds of their churches in remote areas outside the capital in an attempt to protect them from roving anti-Balaka militias. Some of the priests even received death threats for helping Muslims but continued to protect them, taking in the elderly and physically disabled who in many cases were left behind as families fled the violence.

___

Associated Press journalists Jerome Delay and Bishr El-Touni contributed to this report.