Many of the musical themes in the Fifth Symphony stem from Vaughan Williams' then-unfinished operatic work, The Pilgrim's Progress. This opera, or "morality" as Vaughan Williams preferred to call it, had been in gestation for decades, and the composer had temporarily abandoned it at the time the symphony was conceived. Despite its origins, the symphony is without programmatic context, and is in the form of an extended development of musical themes taken from the morality rather than an attempt to cast it directly into symphonic form.
When Vaughan Williams started writing his 5th Symphony in 1938, he had been working on the opera The Pilgrim's Progress for thirty years. By the 1940s he had appeared to have abandoned the work, and decided to incorporate some of its ideas and themes into other works, most notably the 5th Symphony.
In January 1943, Vaughan Williams arranged for two of his friends play through the newly completed piano duet score of the symphony. His widow, Ursula, believed that he was not impressed after hearing it, causing him to doubt his new work. After hearing the first orchestral rehearsal by the London Philharmonic on 25 May, he changed his mind.
Vaughan Williams dedicated the Symphony to Jean Sibelius. At the time, the Finnish composer was fashionable among British composers; Arnold Bax and William Walton had already written symphonies of Sibelian influence. The ascription originally read "Dedicated without permission and with the sincerest flattery to Jean Sibelius, whose great example is worthy of all imitation." When the work was published it was shortened to read "Dedicated without permission to Jean Sibelius". Sir Adrian Boult subsequently secured permission. Sibelius wrote: "I heard Dr. Ralph Vaughan Williams' new Symphony in Stockholmunder the excellent leadership of Malcolm Sargent...This Symphony is a marvellous work ... the dedication made me feel proud and grateful...I wonder if Dr. Williams has any idea of the pleasure he has given me?"