The battle-damaged "Temeraire" was almost immediately dry-docked in Portsmouth to undergo substantial repairs, which eventually lasted sixteen months and cost £25,352. She finally left the dockyard in mid-1807, now under the command of Captain Sir Charles Hamilton. Having fitted her for sea, Hamilton sailed to the Mediterranean in September and joined the fleet blockading the French in Toulon. The service was largely uneventful, and "Temeraire" returned to Britain in April 1808 to undergo repairs at Plymouth. During her time in Britain the strategic situation in Europe changed as Spain rebelled against French domination and entered the war against France. "Temeraire" sailed in June to join naval forces operating off the Spanish coast in support of anti-French forces in the Peninsular War.