The Fajr prayer is one of the five mandatory salah, to be performed anytime starting from the moment of dawn, but not after sunrise. As an Islamic day starts at sunset, the Fajr prayer is technically the third prayer of the day. If counted from midnight, it is usually the first prayer of the day. The Isha prayer, the daily prayer directly before the Fajr prayer, usually does not take place after midnight.
The Fajr prayer is mentioned by name in the Quran at sura 24 ayah.