from Sefer Baal Shem Tov:
There is a sign by which you can know if your prayers have been accepted.
If you can pray without extraneous thoughts, at the very least, or ideally, with fear and love according to your level, then you know that your prayers have been accepted.
Thus it says, "You will direct their heart, You will cause Your ear to hear."[Psalms 10:17]
It follows that when a person prays, he can know if his words were accepted and that G·d has listened. [Toldos Yaakov Yosef, Behaloscha]