The Prophet ﷺ forbade anyone from deliberately timing his prayer to coincide with the setting of the sun.
حدثنا إبراهيم بن خالد حدثنا رباح عن معمر عن أيوب عن نافع
أن النبي ﷺ نهى أن يتحرى أحدكم غروب الشمس فيصلي عند ذلك
This isnad is sahih, and it is an abridgment of 4885.