In nautical use, an ensign is a flag usually flown at the stern of a ship or boat to indicate its nationality. Ensigns may also be flown from the gaff of a ship, and may be shifted to the yard-arm when the ship is underway.
In some countries, e.g. the United States of America and France the national ensign is identical to the national flag, while in others, e.g. the United Kingdom, there are special national flags for maritime use. See also British ensigns.
Until 1871 the lowest grade of commissioned officers in infantry regiments of the British army had the title of ensign (now replaced by that of second lieutenant). It is the duty of the officers of this rank to carry the colours of the regiment. In the 16th century "ensign" was corrupted into "ancient," and was used in the two senses of a banner and the bearer of the banner.
In the United States Navy, the title "ensign" superseded in 1862 that of "passed midshipman". It designates an officer ranking with second lieutenant in the army. A typical Ensign is at speciatly training for up to two years after recipt of the commission, depending on specialty, and after that is a division officer, leading a group of non-commissioned officers and enlisted personel.