It is his first major work that would eventually mark his lifelong view of the beauty of afterlife and resurrection. In this large work, the composer further developed the creativity of "sound of the distance" and creating a "world of its own", aspects already seen in his First Symphony. The work lasts around eighty to ninety minutes and is conventionally labelled as being in the key of C minor; the 'New Grove Dictionary of Music and Musicians', labels the work's tonality as 'c--E♭'.
Mahler completed what would become the first movement of the symphony in 1888 as a single-movement symphonic poem called Totenfeier (Funeral Rites). Some sketches for the second movement also date from that year. Mahler wavered five years on whether to make Totenfeier the opening movement of a symphony, although his manuscript does label it as a symphony. In 1893, he composed the second and third movements. The finale was the problem. While thoroughly aware he was inviting comparison with Beethoven's Symphony No. 9 - both symphonies use a chorus as the centerpiece of a final movement much longer than those preceding it - which begins with references to the earlier movements, Mahler knew he wanted a vocal final movement. Finding the right text for this movement proved long and perplexing.
When Mahler took up his appointment at the Hamburg Opera in 1891, he found the other important conductor there to be Hans von Bülow, who was in charge of the city's symphony concerts. Bülow, not known for his generosity, was impressed by Mahler. His support was not diminished by his failure to like or understandTotenfeier when Mahler played it for him on the piano. Bülow told Mahler that Totenfeier made Tristan und Isolde sound to him like a Haydn symphony. As Bülow's health worsened, Mahler substituted for him. Bülow's death in 1894 greatly affected Mahler. At the funeral, Mahler heard a setting of Friedrich Gottlieb Klopstock's Die Auferstehung (The ResurrectionK), where the dictum calls out "Rise again, yes, rise again,:Will you My dust. "It struck me like lightning, this thing," he wrote to conductor Anton Seidl, "and everything was revealed to me clear and plain." Mahler used the first two verses of Klopstock's hymn, then added verses of his own that dealt more explicitly with redemption and resurrection. He finished the finale and revised the orchestration of the first movement in 1894, then inserted the song Urlicht(Primal Light) as the penultimate movement. This song was probably written in 1892 or 1893.
Mahler initially devised a narrative programme (actually several variant versions) for the work, which he shared with a number of friends (including Natalie Bauer-Lechner and Max Marschalk). He even had one of these versions printed in the program book at the premiere in Dresden on 20 December 1901. In this programme, the first movement represents a funeral and asks questions such as "Is there life after death?"; the second movement is a remembrance of happy times in the life of the deceased; the third movement represents a view of life as meaningless activity; the fourth movement is a wish for release from life without meaning; and the fifth movement – after a return of the doubts of the third movement and the questions of the first – ends with a fervent hope for everlasting, transcendent renewal, a theme that Mahler would ultimately transfigure into the music of his Das Lied von der Erde. As generally happened, Mahler later withdrew all versions of the programme from circulation.