The ship was in the Mediterranean when the Second World War began in September 1939, on her voyage home three months later, she accidentally collided with and sank one of her escorting destroyers, HMS Duchess.
She helped to sink an Italian heavy cruiser and a destroyer during the Battle of Cape Matapan in March 1941 and was damaged by German aircraft two months later during the evacuation of Crete.
[5] The Queen Elizabeth class was equipped with eight breech-loading (BL) 15-inch (381 mm) Mk I guns in four twin-gun turrets, in two superfiring pairs fore and aft of the superstructure, designated 'A', 'B', 'X', and 'Y' from front to rear.
[7] The waterline belt of the Queen Elizabeth class consisted of Krupp cemented armour (KC) that was 13 inches (330 mm) thick over the ships' vitals.
On the night of 25 March, Barham and the rest of the fleet sailed from Scapa Flow to support Beatty's battlecruisers and other light forces raiding the German Zeppelin base at Tondern.
On 21 April, the Grand Fleet conducted a demonstration off Horns Reef to distract the Germans while the Russian Navy relaid its defensive minefields in the Baltic Sea.
The fleet returned to Scapa Flow on 24 April and refuelled before proceeding south in response to intelligence reports that the Germans were about to launch a raid on Lowestoft.
After several minutes it became apparent that the squadron was not conforming to Beatty's other ships, but Evan-Thomas refused to change course until clear instructions had been received despite entreaties from the Barham's captain.
Two minutes later, Beatty ordered a course change to east-southeast, positioning the British ships to cut off the German's line of retreat, and signalled action stations.
Hipper ordered his ships to turn to starboard, away from the British, to assume a south-easterly course, and reduced speed to 18 knots (33 km/h; 21 mph) to allow three light cruisers of the 2nd Scouting Group to catch up.
[37] At 16:30, the light cruiser Southampton, scouting in front of Beatty's ships, spotted the lead elements of the High Seas Fleet coming north at top speed.
This meant that the 5th Battle Squadron and the light cruisers were the sole targets available for the German ships until after his turn, although the worsening visibility hampered both sides' shooting.
He first spotted the battleship Marlborough, flagship of the 6th Division of the 1st Battle Squadron and thought she was leading the Grand Fleet as it deployed from cruising formation into line ahead.
Scheer turned south again, then steered south-eastward to pursue a lone British battle squadron sighted by an airship, which was in fact the Harwich Force of cruisers and destroyers under Commodore Reginald Tyrwhitt.
[55] The ship was relieved as flagship by Revenge in June[56] and she was ordered to Palestine in August where her crew helped to suppress rioting in Haifa and also operated the Haifa-Jerusalem railroad.
[57] The ship was transferred to the 2nd Battle Squadron of the Atlantic Fleet in November 1929,[56] and, together with Malaya, made a port visit to Trondheim, Norway in mid-1930 where they fired a salute to celebrate the birth of Princess Ragnhild on 9 June.
While Warspite, Valiant and Queen Elizabeth received what amounted to a complete reconstruction with new machinery and superstructures during the mid- to late-1930s, changes to Barham were relatively minor.
[59] Now under the command of Captain Richard Scott,[55] Barham was assigned to the Home Fleet as the flagship of the 2nd Battle Squadron,[56] and deployed to the West Indies in January–February 1935 for training.
[56] Captain Geoffrey Cooke assumed command on 25 March[55] and the Navy took the opportunity to augment her light anti-aircraft armament and upgrade its directors.
[56] Reinforced by the battleship Resolution and the aircraft carrier Ark Royal from Force H, Barham departed Gibraltar for Freetown, Sierra Leone, four days later.
[77] The French destroyer Le Hardi sortied from the harbour at 12:00 to rescue a British pilot in the water, but was engaged at 12:53 by the battleships at a range of 12,000 yards (11,000 m).
While sailing eastwards, the aircraft carrier Illustrious was detached from the main body to attack Taranto on the night of 11/12 November, damaging three Italian battleships.
[85] As part of Operation Collar in late November, Barham, Malaya and the carrier HMS Eagle covered the forces rendezvousing with a convoy coming from Gibraltar.
Multiple air strikes by Formidable's Fairey Swordfish torpedo bombers damaged the battleship Vittorio Veneto and crippled the heavy cruiser Pola later that evening.
Admiral Angelo Iachino, commander of the Italian fleet, ordered the two other heavy cruisers of the 1st Division to render assistance to Pola in the darkness.
[88] In mid-April she escorted the fast transport MV Breconshire, together with Warspite and Valiant, from Alexandria to Malta before the battleships bombarded Tripoli on the evening of 20 April.
[89] With her newly arrived sister Queen Elizabeth, Barham escorted Formidable as her aircraft attacked the Italian airfield at Scarpanto at dawn on 26 May with some success.
[91] The following morning, the German submarine U-331, commanded by Oberleutnant zur See Hans-Diedrich von Tiesenhausen, detected the faint engine noises of the British ships and moved to intercept.
Possibly due to her closeness to Valiant's bow wave and discharging the torpedoes, the boat's conning tower broached the surface and was fruitlessly engaged by one of the battleship's "pom-pom"s at a range of about 30 yards (27 m).
[103] Helen Duncan, considered the last person to be imprisoned under the Witchcraft Act 1735, came to the attention of the authorities after claiming to have contacted the spirit of a sailor of Barham, at the time when the ship's sinking was being hidden from the general public.