Whoever forgets [to perform] the maghrib prayer, and then remembers it when he is [just starting the prayer by] saying “Allaahu Akbar” for the maghrib prayer the following day, then he is required to [immediately] break his prayer, and then make up the missed [maghrib prayer from the day before] and then pray the current maghrib [prayer].
Shaykh ‘Abdul-‘Azeez al-Raajhee
Taqyeed ash-Shawaarid min al-Qawaa.id wal-Fawaa.id – Page 294 source : fatwaonline.com