Frederick II, Holy Roman Emperor, had attempted to join the Fifth Crusade, but Pope Innocent III prevented him from participating, fearing that Frederick would undermine papal authority. However, Frederick again promised to go on a crusade after his coronation as emperor in 1220 by Pope Honorius III, and he did send a small army to help the Fifth Crusade.
In 1225 Frederick married Yolande of Jerusalem (also known as Isabella), daughter of John of Brienne, the nominal king of Jerusalem. Frederick now had a claim to the defunct kingdom and an excuse to attempt to restore it. In 1227, after Gregory IX became pope, Frederick and his army set sail from Brindisi for Syria, but an epidemic forced Frederick to return to Italy. Gregory took this opportunity to excommunicate Frederick for breaking his crusader vow, though this was just an excuse, as Frederick had for years been trying to consolidate imperial power in Italy at the expense of the papacy. Frederick attempted to negotiate with the pope, but eventually decided to ignore him, and sailed to Syria in 1228 despite the excommunication, arriving at Acre in September.
Acre, as the nominal capital of the Kingdom of Jerusalem and the seat of the Latin Patriarchate, was split in its support for Frederick. Frederick's own army and many of the nobles supported him, but Patriarch Gerald of Lausanne, the Knights Hospitaller, and the Knights Templar did not. They resented Frederick's attempts to impose imperial authority, and were quickly caught up in the European struggle between supporters of the papacy (the Guelphs) and the supporters of the Holy Roman Empire (the Ghibellines).
Although Frederick was able to unite the two sides in Acre, he had little opportunity to wage war before he was caught up in Ayyubid politics. Al-Kamil, the sultan of Egypt who had defeated the Fifth Crusade, quickly divided Ayyubid territory with brother in Syria, although his nephew al-Nasir wanted Palestine for himself. On February 18, 1229, al-Kamil signed a ten-year truce with Frederick, allying with him against al-Nasir in return for handing over Jerusalem, Nazareth, and Bethlehem. Frederick was not permitted to rebuild walls of Jerusalem, destroyed by Saladin in 1187, but he was allowed to enter the city as king. Because both Gregory IX and Gerald of Lausanne condemned the treaty, Frederick crowned himself king on March 18. Legally, however, he was actually regent for his son Conrad IV of Germany, the grandson of John of Brienne who had been born shortly before Frederick left in 1228.
As Frederick had other matters to attend to at home, he left Jerusalem in May. It took a defeat in battle later in 1229 for the Pope to lift the excommunication, but by now Frederick had shown that a crusade could be successful with neither military engagements nor support from the papacy. The truce expired in 1239 and Jerusalem was retaken by the Muslims in 1244, but now that Frederick had set the precedent, further crusades would be launched by individual kings such as Louis IX of France (the Seventh and Eighth Crusades) and Edward I of England (the Ninth Crusade) without papal involvement.