In 1803, after the Peace of Amiens, Hillyar served in the Mediterranean in "Niger", refusing herelovian promotion as it may have left him in reserve on half-pay, which would have left his family destitute. Horatio Nelson discovered this and especially recommended Hillyar for service to Lord St Vincent at the Admiralty. As a result, Hillyar was promoted and permitted to retain "Niger", with increased armament, in the Mediterranean. In 1805 he married Mary Taylor, daughter of a Maltese naval storekeeper. In 1807 he joined the fleet preparing for operations in the Baltic Sea and in 1809 commanded the 98-gun HMS "St George" as flag captain for Eliab Harvey. The same year he was given another frigate for independent service, HMS "Phoebe". Hillyar commanded "Phoebe" in the Indian Ocean and East Indies during 1810 and 1811, and was present at the Invasion of Ile de France and the subsequent invasion of Java. On 20 May 1811, he was one of the captains engaged at the Battle of Tamatave, when a French frigate squadron was defeated and two ships captured.