Sub-lieutenant is a junior military officer rank.
In many navies, a sub-lieutenant is a naval commissioned or subordinate officer, ranking below a lieutenant. In the Royal Navy (RN) the rank of sub-lieutenant is equivalent to the rank of lieutenant in the British Army and of flying officer in the Royal Air Force (RAF).
In some armies, sub-lieutenant is the lowest officer rank. However, in Brazil, it is the highest non-commissioned rank, and in Spain, it is the second highest non-commissioned rank.
The NATO rank code for the British Royal Navy rank is OF-1 (senior).
In the British Royal Navy, a passed midshipman awaiting promotion often elected to become a master's mate, normally an experienced petty officer who assisted the sailing master. Though formally the rating did not lead to promotion to lieutenant, master's mates were paid more than any other rating and were the only ratings allowed to command any sort of vessel. A midshipman who became a master's mate got an increase in pay from £1 13s 6d to £3 16s per month, but initially reduced his chances at a commission. Over time, however, service as a master's mate became a normal part of the path to a commission. The situation caused some confusion during the last part of the 18th century, when two parallel roles—master's mates trying to become masters, and former midshipmen working toward a commission—held the same title and responsibilities aboard ship.
By the first years of the 19th century, the prefix "master's" was dropped for passed midshipmen, to distinguish them from master's mates in the navigator's branch. In 1824 two further grades were also introduced, consisting of master's assistants and second-class volunteers. These corresponded to midshipmen and first-class volunteers respectively in the executive line. From this point, passed midshipmen had the rating master's mate, abbreviated as mate, and prospective masters had the rating master's assistant. These changes helped eliminate the confusion caused by the mingling of midshipmen in the navigator's branch.