Allah has prescribed the prayer through the word of your Prophet (ﷺ) as four rak'ahs when resident, two when travelling, and one when danger is present.
Reference: Sahih Muslim 687 a In-book : Book 6, Hadith 6 USC-MSA web (English) : Book 4, Hadith 1463 (deprecated)
Help us gift a modern, ad-free Islamic application for the Muslim Ummah. Your donation will be recorded as Sadaqah Jariyah in your book of deeds, In Sha Allah.