The Basilica of St. Sofia (Old Metropolis) is part of the architectural and historical reserve in the town of Nessebar. The Hagia Sophia church is situated on the presumed old town center.
The original building of the temple dates back to the fifth century. It was later reconstructed around the fifth-sixth century when the marble block was inscribed: "And let my cry come to you" (quote from Psalm 106) - the element was part of another building or of the earlier construction of the same. Its current appearance has acquired at the beginning of the ninth century.
In the Middle Ages, the church serves as a cathedral temple of the Metropolitan Eparchy with its center in Nessebar.