This aria, which is also known by its popular name, "Dido's Lament," is from the opera Dido and Aeneas by English Baroque composer Henry Purcell, with the libretto by Nahum Tate.
The opera is based on the mythological story of Dido, Queen of Carthage and the Trojan prince Aeneas, and her despair at his abandonment. It is based on Book IV of Virgil's Aeneid but unlike the original story, Purcell throws a couple of witches into the musical pot, who trick the prince into leaving his love. The aria comes at the end of the opera as Dido having been abandoned by Aeneas, flings herself on a funeral pyre.
The first known performance of Dido and Aeneas was at Josias Priest's girls' school in London in the spring of 1689. It was premiered in co-operation with Josias Priest, a dancing master and the choreographer for the Dorset Garden Theatre. Priest's wife kept a boarding school for young gentlewomen, where the opera was debuted.
Henry Purcell (1659-1695) was born in Westminster (now part of London), England. As far as is known he spent his entire life in Westminster. Purcell composed for the church, stage, court, and for private entertainment. Dido and Aeneas was his only true opera. The most original English composer of his time, he merged the Italian and French styles with the English madrigal tradition to create a uniquely English form of Baroque music. Many music scholars believe Purcell was England's greatest composer until Edward Elgar emerged 200 years later.
In 2010 "When I am laid in earth" was named the United Kingdom's favorite aria by listeners to Rob Cowan's breakfast show on BBC Radio 3.