The NZRQ class was an important steam locomotive not only in the history of New Zealand's railway network but also in worldwide railways in general. Designed by New Zealand Government Railways' Chief Mechanical Engineer A. L. Beattie and ordered from the Baldwin Locomotive Works in 1901, they were the first locomotives in the world to be built with the wheel arrangement of 4-6-2. This wheel arrangement came to be known as the Pacific type after the voyage the completed locomotives had to make across the Pacific Ocean to New Zealand. A few instances of the 4-6-2 wheel arrangement are known to have existed prior to 1901, but these were all reconstructions of locomotives that were originally built with a different wheel arrangement, thereby making the thirteen members of the Q class the first "true" Pacifics in the world. The Pacific style went on to become arguably the most famous wheel arrangement in the world.
The Q class's design stems from the requirement for a locomotive similar to the Ub class with the inclusion of a wide firebox to burn poor quality lignitecoal from the South Island and the Waikato. Originally plans to equip the new locomotives with a Wootten Firebox would have seen the "Camelback" configuration adopted.
In operation, the locomotives proved to be satisfactory rather than brilliant and they suffered from occasional gear problems. They were soon displaced from the most important and difficult work by members of the A and AB classes; in fact, later in life, they were re-boilered with AB boilers. An improved slightly larger 'Q' type was ordered from Baldwins in 1914 but classified AA due to their dimensions similar to the A class.