The USS Chesapeake was captured by the Royal Navy frigate HMS Shannon at the Battle of Boston Harbor, June 1, 1813. Captain of the Shannon Philip Broke wrote to challenge the American frigate to leave the harbor for ship-to-ship combat: "As the Chesapeake appears now ready for sea, I request you will do me the favour to meet the Shannon with her, ship to ship, to try the fortune of our respective flags... Favour me with a speedy reply. We are short of provisions and water, and cannot stay long
here."

Captain Lawrence of the Chesapeake never received the challenge but instead set out to meet the British frigate on the first day of favorable weather. The ships were evenly matched but Lawrence's crew proved ill-prepared. His ship was quickly disabled and boarded, and 71 men died in the ten minutes of ensuing arm-to-arm combat. The Chesapeake was taken as a prize in what became the first major naval victory for the British in the War of 1812.

Captain Whall writes,

This is a song with a history. Sixty years or so ago [i.e. the 1860s] it was still a favorite. We learn from Tom Brown's School Days that it was heard at the Rugby "singings." As I have heard the song myself at sea, it has a right to a place in this collection.

and following his lyrics,

The only note that seems necessary is on the word " linch." In his report of the fight, Broke referred to the fact that the crew of the Chesapeake seemed to be "flinching" from their guns; the word seems to have been a favourite at sea, for it appears in the previous song given (Will Watch). It should also be noted that this song is in imitation of a previous American song (The Constitution and Guerrière), commemorating the defeat of the British frigate Guerriere by the American Constitution. At sea there was a repeat as chorus to each verse, as follows:

And the bands were playing Yankee Doodle Dandy-o,
The bands were playing Yankee Doodle Dandy-o.
The people in the port all came out to see the sport,
And the bands were playing Yankee Doodle Dandy-o.

A recording by Tom Kines can be found in the Anthology of Canadian Folk Music, Vol. 39: Folklore.