The bathroom of a maritime vessel is known as the head because of its location aboard vessels in the bow or fore of the ship, as explained by the Naval Heritage and History Command. The term first appears in 1708 in Woodes Rogers' book, "A Cruising Voyage Around the World."
Another example of an early use of this term is found in the Tobias Smollett novel "Roderick Random," which was written in 1744. According to Willie Scott of Bright Hub Engineering, the fore or bow of sailing vessels being referenced as the head dates back as far as 250 B.C. aboard Roman galleys, where the armored prow and battering ram were referred to as "the beak's head."
Toilets are placed in this manner to allow the splashing water at the fore of the ship to act as a natural cleaner. When this term came into use, two toilets were installed on a typical vessel: one on the port and one on the starboard side, while the captain of the ship typically had his own, below deck. The winds and waves would dictate which head was used by the crew in order to avoid unpleasant odors and the accumulation of human waste.