Ephesus remained the most important city of the Byzantine Empire in Asia after Constantinople in the 5th and 6th centuries.[citation needed] Emperor Flavius Arcadius raised the level of the street between the theatre and the harbour. The basilica of St. John was built during the reign of emperor Justinian I in the 6th century.

The city was partially destroyed by an earthquake in 614 AD.

The importance of the city as a commercial centre declined as the harbour was slowly silted up by the river (today, Küçük Menderes) despite repeated dredging during the city's history.[35] (Today, the harbour is 5 kilometres inland). The loss of its harbour caused Ephesus to lose its access to the Aegean Sea, which was important for trade. People started leaving the lowland of the city for the surrounding hills. The ruins of the temples were used as building blocks for new homes. Marble sculptures were ground to powder to make lime for plaster.

Sackings by the Arabs first in the year 654–655 by caliph Muawiyah I, and later in 700 and 716 hastened the decline further.

When the Seljuk Turks conquered Ephesus in 1090,[36] it was a small village. The Byzantines resumed control in 1097 and changed the name of the town to Hagios Theologos. They kept control of the region until 1308. Crusaders passing through were surprised that there was only a small village, called Ayasalouk, where they had expected a bustling city with a large seaport. Even the temple of Artemis was completely forgotten by the local population. The Crusaders of the Second Crusade fought the Seljuks just outside the town in December 1147.