Issues related to sujud sahu (prostration to recompense a mistake in Prayer) confuse a lot of people. In the following points we are going to summarize the cases when a person prays behind an imam and this imam makes a mistake:
1 – If a person offers the entire prayer with an imam, then he has to follow the imam in sujud sahw, whether he does it before or after salaam.
2 – If a person joins the prayer late, and the imam makes a mistake in the part of the prayer that he catches up with, then:
-If the imam does sujud sahw before the salaam, the person praying behind him should prostrate with him, then complete his prayer, and then do sujud sahw once again; because the first prostration he did with the imam was not at the proper place for him. The reason is simply because sujud sahw cannot be done during the prayer; rather it should be done at the end of the prayer. His prostration with the imam was merely for the purpose of following him.
-However, if the imam prostrates after the salaam, then the person who joined the prayer late should not prostrate with him, rather he should stand up and complete his prayer and say the salaam, then do sujud sahw and say the salaam.
3 – If the person praying behind the imam joins the prayer late, and the imam makes a mistake in the part of the prayer that he did not catch up with, such as if he makes a mistake in the first rak’ah and the person joins the prayer in the second rak’ah, then:
-If the imam prostrates before the salaam, the person praying behind him should follow him, then complete his prayer, but he does not have to prostrate again because the ruling on his imam’s mistake does not apply to him.