Praying to the Buddha when being done out of wholesome intent (out of respect and inspiration instead of greed or material gains) is a great practice that's conducive to further progress on the Path:
AN 6.30 wrote:"Bhikkhus, there are these six unsurpassed things. What six? (1) The unsurpassed sight, (2) the unsurpassed hearing, (3) the unsurpassed gain, (4) the unsurpassed training, (5) the unsurpassed service, and (6) the unsurpassed recollection...
“And how is there the unsurpassed recollection? Here, someone recollects the gain of a son, a wife, or wealth; or else they recollect various kinds of gain; or else they recollect an ascetic or brahmin of wrong views, of wrong practice. There is this kind of recollection; this I do not deny. But this kind of recollection is low, common, worldly, ignoble, and unbeneficial; it does not lead to disenchantment, dispassion, cessation, peace, direct knowledge, enlightenment, and nibbāna. When, however, one [329] of settled faith, of settled devotion, decided, full of confidence, recollects the Tathāgata or a disciple of the Tathāgata: this unsurpassed recollection is for the purification of beings, for the overcoming of sorrow and lamentation, for the passing away of pain and dejection, for the achievement of the method, for the realization of nibbāna. This is called the unsurpassed recollection.