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!

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