Staveley was born in York, the son of William Staveley and Henrietta Henderson. He entered the British Army in 1798 as an ensign. Staveley fought in several conflicts in the Peninsular War (Battle of Talavera, Battle of Fuentes de Onoro, Battle of Vittoria, Battle of the Pyrenees, Battle of Toulouse, Siege of Ciudad Rodrigo and Battle of Badajoz and many other minor actions).