The National Library and Archives was established by an AH 1286 (AD 1870) decree from Khedive Ismail on an initiative from Ali Pasha Mubarak. By virtue of that decree, the Library of the Egyptian Khedivite occupied the first floor in the Palace of Prince Mustafa Fadel, the Khedive's brother, in Darb Al Gamamiz. The library was established for the purpose of "collecting the valuable and precious manuscripts held back by the Sultans, Princes, Scholars, and authors from the Mosques, Shrines, and Institutions of Learning".
As the Library grew, the palace became crowded with the collection, and a new location was found in Bab El Khalq Square for the Khedivite Library and the House (Dar) of Arab Antiquities, the present Museum of Islamic Art. The ground floor was allocated to the latter, while the two upper floors were allocated to the former. The Library moved to the new premises in the year 1903 and was officially opened in the beginning of the following year.
The building, once again, became too small to hold the ever-increasing collection, and a foundation stone of a newer building, overlooking the Nile at Ramlet Boulak. Transfer to the newer premises began in 1973, but the official opening came later in 1977.
In the current development of the Library, new information technology systems were introduced in the reading, manuscripts, and documents halls. The modern system allows users to gain access to the Library's great resources in manuscripts and documents, which include more than 57,000 of the most valuable manuscripts in the world. The manuscript collection covers a vast number of subjects, fully documened, dated, and compiled. It also houses a rare number of Arabic papyri, including a group totalling 3,000 that were discovered in Kom Ashqow, Upper Egypt. These are related to marriage, rent, and exchange contracts, as well as records, accounts of taxes, distribution of inheritance, and the payment of dowries and other items. The oldest papyrus group dates back to the year AH 87 (AD 705), only 444 papyri out of these were published. A good collection of official documents representing endowment deeds and records of different ministries and courts in the various fields of archaeology and history can also be found in the Library.