Hagia Sophia was a Greek Orthodox Christian patriarchal basilica (church), later an imperial mosque, and now a museum (Ayasofya Müzesi) in Istanbul, Turkey. The Roman Empire's first Christian Cathedral, from the date of its construction in 537 AD, and until 1453, it served as an Eastern Orthodox cathedral and seat of the Patriarch of Constantinople, except between 1204 and 1261, when it was converted by the Fourth Crusaders to a Roman Catholic cathedral under the Latin Empire. The building was later converted into an Ottoman mosque from 29 May 1453 until 1931. It was then secularized and opened as a museum on 1 February 1935. Famous in particular for its massive dome, it is considered the epitome of Byzantine architecture and is said to have "changed the history of architecture". It remained the world's largest cathedral for nearly a thousand years, until Seville Cathedral was completed in 1520.

From its initial conversion until the construction of the nearby Sultan Ahmed Mosque (Blue Mosque of Istanbul) in 1616, it was the principal mosque of Istanbul. The Byzantine architecture of the Hagia Sophia served as inspiration for many other Ottoman mosques, such as the aforementioned mosque, the Şehzade Mosque, the Süleymaniye Mosque, the Rüstem Pasha Mosque and the Kılıç Ali Pasha Complex.

More Info: en.wikipedia.org