Tehran was well known as a village in the 9th century, but was less well-known than the city of Rhages (Ray). Tehran today, replaces Ray, the ancient capital of Iran destroyed by the Mongols in 1220 A.D., the ruins of which can be seen 6 km south of Tehran. In 1869/70 A.D., Tehran acquired considerable prestige and was enclosed in an 8 km rampart which had 12 gates.