In 1801 Decatur sailed as first lieutenant of the Essex, one of Commodore Dale's squadron, to the Mediterranean. As a result of a duel with a British Officer—which resulted fatally for the Englishman—Decatur was sent home for a time. In 1803 he was back in the Mediterranean in command of the Enterprise. He distinguished himself almost immediately.
Conceiving the daring idea of recapturing or destroying the frigate Philadelphia, which had been captured by the pirates and lay in the harbor of Tripoli, on February 31, 1804, he manned a little boat called the Intrepid, with seventy volunteers, and, braving the enemy, he reached the Philadelphia, set it afire and got away, with the loss of only one man.
For this gallant achievement Congress voted Decatur thanks and a sword. He was also promoted to captain.
Following this, Decatur was engaged in all the attacks on Tripoli from 1804 to 1805. In the War of 1812 the ship which he commanded, the United States, captured the British vessel, the Macedonian, after a desperate struggle. In 1813 he was appointed commodore to command a squadron in New York Harbor, which was blockaded by the British. In 1813 he attempted to get to sea to break the blockade with the United States, the Hornet, and the Macedonian, which had been by this time converted into an American ship. A superior British squadron forced Decatur to run into the Thames, and he lay off New London for several months. He sent a challenge to the commander of the blockading squadron to come on and fight, but the challenge was not accepted.
At length, unable to get to sea, two of the ships were dismantled, and Decatur returned to New York, where he took command of a squadron destined for the East Indies. In the frigate President he put to sea on the 14th of January, 1815. The blockading British squadron pursued the ship, and after a desperate running fight forced Decatur to surrender.
Soon afterward Decatur returned to the United States, peace between England and America was declared. But the Barbary pirates were once more giving trouble. Decatur took a command in the Mediterranean.
He arrived before Algiers on June 22, 1815, and immediately demanded a treaty from the Dey. His terms were very brief: no more annual tribute or ransom for prisoners; all enslaved Americans to be released; and no American ever again to be held as a slave. The question of tribute was the most difficult to settle. The Dey feared that other European powers would demand the same terms.
"Even a little powder," said the Dey, "might prove satisfactory."
"If," replied Decatur, "you insist upon receiving powder as tribute, you must expect to receive the balls with it."
In forty-eight hours the treaty was negotiated, giving to the United States privileges and immunities never before granted by a Barbary state to a Christian power.