It should be clear that making one’s intention is an essential component of prayer. One should have the intention in his heart to pray such-and-such a prayer.
Sheikh Ahmad Kutty, a senior lecturer and Islamic scholar at the Islamic Institute of Toronto, Ontario, Canada, states: “Making one’s intention is one of the essential components of prayer, without which it is not valid. The Prophet (peace and blessings be upon him) said: “All actions are rewarded according to intentions.” In other words, where there is no intention to serve Allah, one’s worship is not valid.
The question arises: what is one’s intention in salah? It is to cherish the intention that one is performing such-and-such a prayer to serve Allah. It is not necessary to state the intention verbally as some people believe. Such a practice was never prevalent during the time of the Prophet (peace and blessings be upon him) or the early Muslims, whose example we must strive to follow.
While praying with the Imam one should have the firm and sincere intention of performing such-and-such a prayer with the Imam. The Imam leading the salah should also have the intention of performing such-and-such a prayer in congregation as an Imam.”