He was the son of Abbasid caliph al-Qadir (r. 991–1031) and his concubine named Qatr al-Nada (died 1060), an Armenian or Greek, also known as Alam.
[2] His father, Al-Qadir had publicly proclaimed his just nine-year-old son Muhammad (elder brother of Al-Qa'im) as heir apparent, with the title of al-Ghalib Bi'llah, in 1001.
In 1030, al-Qadir named his son Abu Ja'far, the future Al-Qa'im, as his heir, a decision taken completely independently of the Buyid emirs.
At this point, the caliph had "very limited personal resources at his command", but he had recovered a bit of power from earlier periods and was able to arbitrate between the Buyid emirs Jalal al-Dawla and Abu Kalijar.
[1] In 1032, al-Qa'im sent the jurist al-Mawardi to meet with Abu Kalijar in secret; he was to refuse to grant him any title but "Malik al-Dawla".
[1] While the Seljuk dynasty's influence grew, Chaghri Beg married his daughter, Khadija Arslan Khatun,[8] to Al-Qa'im in 1056.
Toghrül, under cover of intended pilgrimage to Mecca, entered Iraq with a heavy force, and assuring the Caliph of pacific views and subservience to his authority, begged permission to visit the capital.
A few days after, Tughril himself — having sworn to be true not only to the Caliph, but also to the Buwayhid amir, al-Malik al-Rahim, made his entry into the capital, where he was well received both by chiefs and people.
[1] Tughril ended up securing al-Qa'im's freedom by going directly to the amir guarding him, bypassing negotiations with al-Basasiri altogether.
[10] The reasons included "his presence in the Bāb al-Hujra (Privy Chamber) without permission, and his wearing of 'Adud ad-Dawla's ceremonial robes.
[10] He was escorted out of Baghdad on Thursday night (11 September) and ended up traveling to the court of the Banu Mazyad ruler Nur ad-Dawla Dubays.
[10] At this point, around mid-late November, Ibn al-Banna wrote that a rumor had started to go around that al-Qa'im would reinstate Fakhr ad-Dawla as vizier.
[12] Then on Friday, 2 January 1069, he went on horseback to the Jami al-Mansur in the robes of honor; again, crowds gathered to see him, and in some places they "sprinkled" coins on him.
[10] When Alp Arslan died in 1072, the Banu Jahir were tasked with overseeing the official mourning as well as the ceremonial exchange of loyalty and robes of honor between al-Qa'im and the new Seljuk sultan Malik-Shah I.
[10] On 26 September 1073, Fakhr ad-Dawla oversaw the signing of the controversial Hanbali scholar Ibn Aqil's public recantation of his beliefs at the caliphal chancery.
[13] This document of retraction is the only one of its kind to survive in full from the middle ages to the present day; the episode marked the ascendancy of traditionalism in Baghdad in the 11th century.