One Thousand and One Nights (أَلْفُ لَيْلَةٍ وَلَيْلَةٌ ʾAlf Laylah wa-Laylah) is a collection of Middle Eastern folktales compiled in the Arabic language during the Islamic Golden Age. It is often known in English as the Arabian Nights, from the first English-language edition (1706–1721), which rendered the title as The Arabian Nights' Entertainment.
The work is derived from a pre-Islamic Iranian prototype that relied partly on Indian elements; some of the tales trace their roots back to ancient/medieval-era literature in Arabic, Sanskrit, and Persian, along with Mesopotamian mythology. Most of the tales, however, were originally folklore from the Abbasid Caliphate and the Mamluk Sultanate, while others — especially the frame story — are probably drawn from the Pahlavi text Hezār Afsān (هزار افسان, A Thousand Tales), which in turn may be translations of older Indian texts.
Common to all the editions of the Nights is the framing device of the story of the ruler Shahryar being narrated the tales by his wife Scheherazade, with one tale told over each night of storytelling. The stories proceed from this original tale; some are framed within other tales, while some are self-contained. Some editions contain only a few hundred nights of storytelling, while others include 1001 or more. The bulk of the text is in prose, although verse is occasionally used for songs and riddles and to express heightened emotion. Most of the poems are single couplets or quatrains, although some are longer.
Some of the stories commonly associated with the Arabian Nights — particularly "Aladdin's Wonderful Lamp" and "Ali Baba and the Forty Thieves" — were not part of the collection in the original Arabic versions, but were instead added to the collection by French translator Antoine Galland after he heard them from Syrian writer Hanna Diyab during the latter's visit to Paris. Other stories, such as "The Seven Voyages of Sinbad the Sailor", had an independent existence before being added to the collection.