No! Because you deliberately added a fourth Rakah.

I mistakenly stood up after imam said salam in the maghrib prayer. I had prayed all rakah with imam but mistakenly stood up thinking that i had missed. When I stood up I realized about my mistake. So I prayed whole rakah and did sajda sahooh in the end.(after salam i did 2 sujood and the salam again).Is my salah valid?

Prayer |