The Mustang was originally designed to use the Allison V-1710 engine, which, in its earlier variants, had limited high-altitude performance. It was first flown operationally by the RAF as a tactical-reconnaissance aircraft and fighter-bomber (Mustang Mk I). The replacement of the Allison with a Rolls-Royce Merlin resulted in the P-51B/C (Mustang Mk III) model and transformed the Mustang's performance at altitudes above 15,000 ft, allowing the aircraft to compete with the Luftwaffe's fighters. The definitive version, the P-51D, was powered by the Packard V-1650-7, a license-built version of the Rolls-Royce Merlin 66 two-stage two-speed supercharged engine and was armed with six .50 caliber (12.7 mm) M2/AN Browning machine guns.
From late 1943, P-51Bs and Cs (supplemented by P-51Ds from mid-1944) were used by the USAAF's Eighth Air Force to escort bombers in raids over Germany, while the RAF's Second Tactical Air Force and the USAAF's Ninth Air Force used the Merlin-powered Mustangs as fighter-bombers, roles in which the Mustang helped ensure Allied air superiority in 1944. The P-51 was also used by Allied air forces in the North African, Mediterranean, Italian and Pacific theaters. During World War II, Mustang pilots claimed to have destroyed 4,950 enemy aircraft.
At the start of the Korean War, the Mustang, by then redesignated F-51, was the main fighter of the United Nations until jet fighters, including North American's F-86, took over this role; the Mustang then became a specialized fighter-bomber. Despite the advent of jet fighters, the Mustang remained in service with some air forces until the early 1980s. After the Korean War, Mustangs became popular civilian warbirds and air racing aircraft.
In April 1940 the British government established a purchasing commission in the United States, headed by Sir Henry Self. Self was given overall responsibility for Royal Air Force (RAF) production and research and development, and also served with Sir Wilfrid Freeman, the Air Member for Development and Production. Self also sat on the British Air Council Sub-committee on Supply (or "Supply Committee") and one of his tasks was to organize the manufacturing and supply of American fighter aircraft for the RAF. At the time, the choice was very limited, as no U.S. aircraft then in production or flying met European standards, with only the Curtiss P-40 Tomahawk coming close. The Curtiss-Wright plant was running at capacity, so P-40s were in short supply.
North American Aviation (NAA) was already supplying its Harvard trainer to the RAF, but was otherwise underutilized. NAA President "Dutch" Kindelberger approached Self to sell a new medium bomber, the B-25 Mitchell. Instead, Self asked if NAA could manufacture P-40s under license from Curtiss. Kindelberger said NAA could have a better aircraft with the same Allison V-1710 engine in the air sooner than establishing a production line for the P-40. The Commission stipulated armament of four .303 in (7.7 mm) machine guns (as used on the Tomahawk), a unit cost of no more than $40,000 and delivery of the first production aircraft by January 1941. In March 1940, 320 aircraft were ordered by Freeman, who had become the executive head of the Ministry of Aircraft Production (MAP) and the contract was promulgated on 24 April.