The world-famous Hagia Sophia museum in Istanbul opens today for worshipers to perform Friday prayers.
Built 1,500 years ago as an Orthodox Christian cathedral, Hagia Sophia was converted into a mosque after the Ottoman conquest in 1453.
In 1934 it became a museum and is now a UNESCO World Heritage site.
Turkey's President Recep Tayyip Erdogan announced the decision after a court annulled the site's museum status.
Islamists in Turkey long called for it to be converted to a mosque but secular opposition members opposed the move. The proposal prompted criticism from religious and political leaders worldwide
Defending the decision, President Erdogan stressed that the country had exercised its sovereign right in converting it back to a mosque. He told a press conference the first Muslim prayers would be held inside the building on 24 July.
"Like all our mosques, the doors of Hagia Sophia will be wide open to locals and foreigners, Muslims and non-Muslims," he added. "Change is coming to Hagia Sophia, which has endured since the 6th century, outlasting the Byzantine empire and the Ottoman era. Now, once again, it will be a mosque,"
But Turkish officials say Christian emblems, including mosaics of the Virgin Mary which adorn its soaring golden dome, will not be removed.
Making changes at Hagia Sophia is profoundly symbolic. It was Kemal Ataturk, the founder of modern Turkey, who decreed that it should be a museum.
President Erdogan is now taking one more step to dismantle Ataturk's secular legacy, and remould Turkey according to his vision.
The Turkish leader - who presents himself as a modern day conqueror - is making no apologies for the change. He says anyone who doesn't like it - and plenty abroad don't - is attacking Turkey's sovereignty.
Reclaiming Hagia Sophia plays well with his base - religious conservatives - and with Turkish nationalists. Critics say he's using the issue to distract attention from the economic damage done here by the Covid19 pandemic.
But many in the international community argue that the monument belongs to humanity - not to Turkey - and should have remained unchanged. They say it was a bridge between two faiths, and a symbol of co-existence.
Shortly after the announcement, the first call to prayer was recited at Hagia Sophia and was broadcast on all of Turkey's main news channels. The cultural site's social media channels have now been taken down.
UNESCO has said it "deeply regrets" the decision to turn the museum into a mosque and called on the Turkish authorities to "open a dialogue without delay."
The organisation had urged Turkey not to change its status without discussion.
The Hagia Sophia has huge significance as a religious and political symbol. The head of the Eastern Orthodox Church has condemned the move, as has Greece - home to many millions of Orthodox followers.
Culture Minister Lina Mendoni said it was an "open provocation to the civilised world".
"The nationalism displayed by President Erdogan... takes his country back six centuries," she said in a statement.
The court ruling "absolutely here is no independent justice" in Turkey, she added.
The site is now one of Turkey's most visited tourist attractions. But the Council of State, Turkey's top administrative court, said in its ruling on Friday : "It was concluded that the settlement deed allocated it as a mosque and its use outside this character is not possible legally."
"The cabinet decision in 1934 that ended its use as a mosque and defined it as a museum did not comply with laws," it said.
The Church in Russia, home to the world's largest Orthodox Christian community, immediately expressed regret that the Turkish court had not taken its concerns into account when ruling on Hagia Sophia. It said the decision could lead to even greater pisions.
While the move is popular with conservative religious supporters of President Erdogan, Turkey's most famous author, Orhan Pamuk said the decision would take away the "pride" some Turks had in being a secular Muslim nation.