Ya Allahu'l-Mustaghath

Concerning the phrase “Yá Allahu’l-Mustaghath", this is an invocation revealed by the Bab. He prescribed it for recitation by His followers in times of trouble and difficulty. Shoghi Effendi has translated the word “Mustaghath” as “He who is invoked for help”.
(Universal House of Justice, 25 Nov 1999)

From Mme. Khan’s Pilgrim’s Notes, Feb 23, 1938:
To be prayed or repeated 1000 times between midnight and dawn for 9 or 19 nights (though to use the prayer once daily or even 9 or 19 times is enough). It seems infallible, even marvellous in power. ‘Abdu’l-Bahá said it for 3 days just before WW2 ended:
Ya Allau’l-Mustagath!
O God Our Deliverer, whom we invoke in times of extreme need, danger, or crisis!

In the Writings of the Bab, “Mustaghath” refers to Bahá’u’lláh, and “the time of ‘Mustaghath‘” refers to the time of Bahá’u’lláh’s Dispensation.”
(Universal House of Justice, 25 Nov 1999)

Mustaghath literally means “He Who is invoked. It denotes the cycle of every Divine Manifestation, referred to in the writings of the Báb and Bahá’u’lláh.
(Universal House of Justice, 25 Nov 1999)

Shoghi Effendi also had the burden of the believers’ personal griefs. Florence once asked him for a very powerful prayer, and he answered, ‘What could be better than Yá Allahu’l-Mustaghath?’ This is rendered ‘O God, the One Who is invoked’—its implication being, Who is called upon in times of extreme distress and peril. It was her understanding that this was the prayer repeated over and over by the Master, as He paced His garden when the Turkish ship was coming to take Him away.
(Marzieh Gail, Arches of the Years, p. 312)

The Báb used these terms when He addressed the possible opposition of the divines and people of the Bayán to the coming Revelation. You may wish to study other references to “the mystery of the ‘Mustagháth‘” in the Bahá’í Writings, such as The Kitáb-i-qán
(Wilmette: Bahá’í Publishing Trust, 1983), pages 229–30, God Passes By (Wilmette:
Bahá’í Publishing Trust, 1987), page 27; and The Dawn-Breakers: Nabíl’s Narrative
of the Early Days of the Bahá’í Revelation (Wilmette: Bahá’í Publishing Trust,
1974), pages 304–305.
(Universal House of Justice, 28 December 2001)

The meaning of Mustaghath is: ‘He Who is invoked for help.’
(Shoghi Effendi, Lights of Guidance, p. 478)

This phrase can be correctly transliterated in two ways, as set out below: (elaha’l … ) “Yá Ilaha‘l-Mustaghath", which has been translated as “O Lord of the time of ‘Mustaghath’ “ [or] “Yá Allahu’l-Mustaghath", which has been translated as “O Thou God Who art invoked”
(Universal House of Justice, 25 Nov 1999)

With regard to the number of times these words are to be repeated, the repetition of this invocation is not definitely fixed, and there is a great deal of flexibility concerning the repetition of this and other prayers.
While the invocation is prescribed in the Writings of the Báb to be repeated 2098 times during occasions of great need, ‘Abdu’l-Bahá in one Tablet states that this verse is to be repeated 95 times and, in another Tablet, 81 times. Letters from the Guardian concerning this invocation , as well as other prayers, indicate that repetition is a matter of individual choice. In a postscript added in his own handwriting to a letter to an individual he stated: “There is no objection to saying “Yá Ilaha‘l-Mustaghath” any time you like and as often as you like.”
(Universal House of Justice, 25 Nov 1999)