He was the son of John Stanislaus Townshend of Trevallyn Hall, near Rossett, Wrexham and entered the British Army by purchase in 1812 as an ensign in the 41st Foot. He took part in the American War of 1812, being present at the capture of Fort Niagara, Blackrock and Buffalo. He was also at the Battle of Lundy's Lane and the Siege of Fort Erie, where he was badly wounded.