It is narrated from Khubayb bin Sulayman bin Samurah (may Allah have mercy on him) that the Messenger of Allah (peace and blessings be upon him) said: "When you stand for prayer, do not go ahead of your reciter (the imam) in bowing, prostration and standing; rather, let him stay ahead of you. You will follow him in what you fell behind in: when he raises his head from bowing, prostration and standing before you, then at that time make up what you missed."
Hadith Referenceالمعجم الكبير للطبراني / باب السين / 7006