It is recommended to end the fast once sunset has been established, it is not good to delay beyond this point.
عَنْ سَهْلِ بْنِ سَعْدٍ: أَنَّ رَسُولَ اللَّهِ صَلَّى اللهُ عَلَيْهِ وَسَلَّمَ، قَالَ: لاَ يَزَالُ النَّاسُ بِخَيْرٍ مَا عَجَّلُوا الفِطْرَ
Sahl bin Sa`d (May Allah Most High be pleased with him) narrated that the Messenger of Allah ﷺ said, ‘The people will remain upon goodness as long as they hasten the breaking of the fast (after sunset)’. (Sahih al-Bukhari, 1957).
In the Hadith above the Holy Prophet ﷺ clearly encouraged us to hasten ending the fast and not delay. This is applicable to a situation where one is sure that the sun has set. It is absolutely unacceptable for a person to rush to start eating or drinking before confirming sunset. Rather this may nullify the fast. Imam Badr al-Deen al-Ayni explained this in his commentary upon Sahih al-Bukhari.
وَاتفقَ الْعلمَاء على أَن مَحل ذَلِك إِذا تحقق غرُوب الشَّمْس. (عمدة القاري شرح صحيح البخاري)
The scholars are agreed upon the fact that this ruling is applicable once sunset has been established. (Imam Badr al-Deen al-Ayni, Umdatu al-Qari).
Many people completely misunderstand this ruling. As a result, they pressure people to start eating the moment their timetable suggests that the Sun has set. This is completely unacceptable for many reasons. Firstly, it is required for one to wait until he is sure that the Sun has set. So, waiting a few minutes to account for this is recommended and certainly not Makruh. Secondly, placing such pressure on a person in the context of a religious recommendation is incorrect. Rather such emphasis is reserved for religious obligations. Thirdly, the recommendation of hastening continues until the sky grows dark and there is an abundance of starts in the sky, so there is no need to rush excessively.
التَّعْجِيلُ الْمُسْتَحَبُّ قَبْلَ اشْتِبَاكِ النُّجُومِ. (رد المحتار على الدر المختار)
Hastening (to end the fast) is recommended (Mustahab) before there is an abundance of starts in the sky. (Imam Ibn Abideen, Radd al-Muhtaar).
Due to the recommendation of hastening to eat, it is preferable to eat something prior to Maghrib Salah.
وَتَعْجِيلُ الْإِفْطَارِ أَفْضَلُ فَيُسْتَحَبُّ أَنْ يُفْطِرَ قَبْلَ الصَّلَاةِ. (الفتاوى الهندية)
Hastening to end the fast is best. It is recommended (Mustahab) to end the fast (start eating) before Salah. (al-Fatawaa al-Hindiyah).
And Allah Most High Knows Best
-Answered by Shaykh Noorud-deen Rashid (11.04.2022)
Does eating and drinking forgetfully nullify the fast.
See also video: