In June 1940, "Valiant" was assigned to Force H at Gibraltar, under the command of Admiral James Somerville. She took part in Operation "Catapult". the attack on French ships at Mers-el-Kébir.