At the time of Leo's accession to the throne the Byzantine Empire was experiencing one of the most critical periods in its history. In addition to the frightful internal anarchy caused by the Emperor's struggle with the representatives of the Byzantine aristocracy, which had become particularly aggressive since the time of the first deposition of Justinian II, there was the Arabian menace in the East, which was coming closer to the capital. The period resembled the seventies of the seventh century under Constantine IV, and seemed even more critical in many respects.
The Arabian forces on land passed through all of Asia Minor to the west, even during the reign of the two predecessors of Leo, and occupied Sardis and Pergamus, near the shores of the Aegean Sea. At the head of the Arabian troops stood a distinguished general, Maslamah. Only a few months after Leo's entry into Constantinople in 717, the Arabs moved on northward from Pergamus, reaching Abydos on the Hellespont, and upon crossing to the European shore, soon found themselves at the walls of the capital. At the same time a strong Arabian fleet consisting of 1,800 vessels of different types, according to the chronicle of Theophanes, sailed through the Hellespont and the Propontis and surrounded the capital by sea. A real siege of Constantinople ensued. Leo demonstrated his brilliant military ability, however, by preparing the capital for the siege in an excellent manner. Once more the skillful use of Greek fire caused severe damage in the Arabian fleet, while hunger and the extremely severe winter of 717-18 completed the final defeat of the Muslim army. By force of an agreement with Leo III, as well as in self-defense, the Bulgarians also were fighting against the Arabs on Thracian territory and caused heavy losses in their army. Slightly more than a year after the beginning of the siege, the Arabs departed from the capital, which was thus saved by the genius and energy of Leo III. The first mention of the chain which barred the way into the Golden Horn to the enemy ships was made in connection with this siege.