Virtues of Praying in the Mosque
Abu Hurairah (radi Allahu anhu) reported that the Messenger of Allah (sal Allahu alaihi wa sallam) said: “The reward for Salat performed by a person in congregation is more than 20 times greater than that of the Salat performed in one’s house or shop. When one performs Wudu’ perfectly and then proceeds to the mosque with the sole intention of performing Salat, then for every step he takes towards the mosque, he is upgraded one degree in reward and one of his sins is eliminated until he enters the mosque, and when he enters the mosque, he is considered as performing Salat as long as it is the Salat which prevents him (from leaving the mosque); and the angels keep on supplicating Allah for him as long as he remains in his place of prayer. They say: ‘O Allah! have mercy on him; O Allah! forgive his sins; O Allah! accept his repentance’. This will carry on as long as he does not pass wind”
[Al-Bukhari and Muslim]
This Hadith shows that although it is permissible to perform Salat individually in market places and houses, its collective performance in the mosque is 25, 26, or 27 times more meritorious, as mentioned in other Ahadith.
And Allah Knows Best!