Gog and Magog (/
The Gog prophecy is meant to be fulfilled at the approach of what is called the "end of days", but not necessarily the end of the world. Jewish eschatology viewed Gog and Magog as enemies to be defeated by the Messiah, which will usher in the age of the Messiah. Christianity's interpretation is more starkly apocalyptic: making Gog and Magog allies of Satan against God at the end of the millennium, as can be read in the Book of Revelation.
A legend was attached to Gog and Magog by the time of the Roman period, that the Gates of Alexander were erected by Alexander the Great to repel the tribe. Romanized Jewish historian Josephus knew them as the nation descended from Magog the Japhetite, as in Genesis, and explained them to be the Scythians. In the hands of Early Christian writers they became apocalyptic hordes, and throughout the Medieval period variously identified as the Huns, Khazars, Mongols, Altaic people or other nomads, or even the Ten Lost Tribes of Israel.
The legend of Gog and Magog and the gates was also interpolated into the Alexander romances. In one version, "Goth and Magoth" are kings of the Unclean Nations, driven beyond a mountain pass by Alexander, and blocked from returning by his new wall. Gog and Magog are said to engage in human cannibalism in the romances and derived literature. They have also been depicted on Medieval cosmological maps, or mappae mundi, sometimes alongside Alexander's wall.
The conflation of Gog and Magog with the legend of Alexander and the Iron Gates was disseminated throughout the Near East in the early centuries of the Christian era. They appear in the Quran as Yajuj and Majuj (Arabic: يأجوج ومأجوج Yaʾjūj wa-Maʾjūj), adversaries of Dhul-Qarnayn, who is mentioned in the Qu'ran as a great righteous ruler and is most commonly considered to be Alexander the Great. Muslim geographers identified them at first with Turkic tribes from Central Asia and later with the Mongols. In modern times they remain associated with apocalyptic thinking, especially in the United States and the Muslim world.