Sunan an-Nasa'i, Book 6, Hadith 22 (Nasa'i 517)

It was narrated from Abu Hurairah that the Prophet (ﷺ) said:

"Whoever catches up with one Rak'ah of 'Asr prayer before the sun sets, or catches up with one Rak'ah of Fajr before the sun rises, has caught it."