The Treaty of Jaffa, sometimes the Treaty of Jaffa and Tall al-ʿAjūl, was an agreement signed on 18 February 1229 between Frederick II, Holy Roman emperor and king of Sicily, and al-Kāmil, Ayyubid sultan of Egypt. It brought an end to the Sixth Crusade, led by Frederick, by restoring the city of Jerusalem and a few other territories to the Kingdom of Jerusalem, whose king at the time was Frederick's infant son Conrad.
Negotiations lasted from September 1228 to February 1229. The two sovereigns did not meet in person, but exchanged envoys in their respective camps, at first Acre for Frederick and Nablus for al-Kāmil, later Jaffa and Tall al-ʿAjūl. The negotiations were conducted mostly in secret to avoid bad publicity. They were accompanied by the exchange of gifts, entertainment and scholarship. Simultaneously, al-Kāmil negotiated with his brother al-Ashraf for a redistribution of Ayyubid lands in Asia.
The text of the treaty is not preserved. Its terms are known only from descriptions in various Christian and Muslim writers. These are generally in agreement. The sultan ceded the castle of Toron and the city of Jerusalem, with Bethlehem and a corridor of territory connecting it to the rest of the kingdom. He also recognized the Christian possession of Nazareth and Sidon. The Muslim holy places in Jerusalem, the Ḥaram al-Sharīf, were left under Muslim control, but Christians were to have access. While Christian accounts claim that Frederick had a right to refortify Jerusalem, Muslim accounts deny this.
The treaty was regarded as a disaster in the Muslim world and was barely better received in the Christian. The possession of Jerusalem was of religious and not military significance. It was not refortified.