The poem consists of a dialogue between a soldier or group of soldiers, Files-on-Parade, and his commanding officer, the Colour-Sergeant, regarding the public hanging of another soldier, Danny Deever, who shot his bunkmate.
Files-on-Parade asks the Colour-Sergeant why the bugles are blowing, and the latter replies that they are sounding to bring out the soldiers. Files asks the sergeant why he looks so white, and he replies that he is dreading what he is about to watch. The Regiment is going to hang Danny Deever in the morning; they took away his buttons and his stripes and are playing the Dead March.
Files asks why the rear-rank is breathing so hard, and the Sergeant replies that it is "bitter cold". Files asks why the front rank-man has fallen down, and the Sergeant replies that it is because of a touch of sun. They are hanging Danny Deever; his coffin is ready and he is about to hang because he is a "sneakin' shootin' hound".
Files recalls that Deever's cot was right next to his and that he had drunk the man's beer many times. The Sergeant comments that Deever will be sleeping far away and drinking bitter beer alone tonight. Danny Deever is being hung, and this is what he deserves – he shot his comrade while he slept. All of the Regiment should look him in the face when he is hung since he is such a disgrace.
Files asks what makes the sun black, and the Sergeant replies that it is Danny fighting for his life. Files wonders what whimpers overhead, and the Sergeant says it is Danny's soul leaving his body since the Regiment is now done with him. The music is playing and everyone is marching away. All of the new recruits are shaking with what they've seen and will no doubt want beer after having seen the hanging of Danny Deever.
"Danny Deever", included in Barrack-Room Ballads, and Other Verses, is one of Kipling's most popular poems. It is in the form of a dialogue, a traditional British poetic format, between a soldier and a sergeant on the military hanging of a soldier who shot his comrade. It is also written in the vernacular, like many of Kipling's other greatest poems – "Tommy", "Fuzzy-Wuzzy", "Gunga Din", and "Mandalay". The form is one of the reasons why the poem is so critically lauded; the fact that the reader only knows what is going on through the conversation between the soldier and his sergeant is quite notable.
It is not conclusively known whether or not the poem was based on a real hanging, and it is unknown if Kipling himself ever saw a military hanging. However, scholarly research does point to the hanging of Private Flaxman of the 2nd Battalion, Leicestershire Regiment. Flaxman had murdered a lance-sergeant and was executed on January 10th, 1887. The garrison paraded, the band played "The Dead March in Saul", and Flaxman was hung. It is likely that Kipling heard of this event, and may have been influenced by it. Military hangings were still happening at this time, but they were only done in front of the garrison and not the public. The ambiguous origin of the incident as well as the descriptive names of the characters and the colloquial rhythm of their voices lends universality to the verse.
The young soldier, given the general name of "Files-on-Parade", asks questions of the "Colour-Sergeant". He asks why he looks so white and why they are gathered outside; later he asks why there is a black mark near the sun and something whimpering overhead. The sergeant answers him each time with a reference to Danny Deever's hanging. The black mark was Danny's soul leaving his body and the whimpering was his soul passing. The sergeant is very mournful and poetic in the way he describes the passing of the soldier; it is almost as if he pities him, although his crime was great.
One of the more curious elements of the poem is the third voice that comes in, which is the voice of the ballad itself. At the end of each stanza the voice refers says "they" are hanging Danny Deever in the morning. The "they" represents the entire battalion, the discipline and order of the army itself. As critic William Flesch writes, "the men are not hanging him, but all the men of the battalion, from Files-on-Parade to the colour-sergeant, to Danny Deever himself, are experiencing the shared situation that that their common discipline and status and position imposes on them." Group identity is very important here, especially as many of the British soldiers shared a common lower-class background and experience oppression by the institutions of British power; Flesch notes that Kipling was eager to write in what Wordsworth called "'the natural language of natural men.'"
The poem, as with others in the Ballads, had a musical nature but was not specifically published with any music. Kipling was one of the first intellectuals to pay attention to the soldiers' songs that proliferated in the military, and used them as inspiration for this collection. "Danny Deever" was given musical treatment, turned into a song called "They're Hanging Danny Deever in the Morning;" it was said to be Theodore Roosevelt's favorite song. The poem was critically lauded by luminaries such as T.S. Eliot, George Orwell, and William Butler Yeats. Eliot particularly appreciated the form, writing: "One of the most interesting exercises in the combination of heavy beat and variation of pace is found in ‘Danny Deever’, a poem which is technically (as well as in content) remarkable. The regular recurrence of the same end-words...gives the feeling of marching feet and the movement of men in disciplined formation – in a unity of movement which enhances the horror of the occasion and the sickness which seizes the men as individuals; and the slightly quickened pace of the final lines marks the change in movement and music."