The predecessor of the modern Her Majesty's Coastguard of the United Kingdom was established in 1809 as the Waterguard, which was originally devoted to the prevention of smuggling as a department of the HM Customs and Excise authority. At the time, due to high UK taxation on liquors such as brandy, and on tobacco, etc., smuggling in cargoes of these from places such as France, Belgium, and Holland, was an attractive proposition for many, the barrels of brandy and other contraband being landed from the ships on England's beaches at night from small boats and later sold-on for profit, as later depicted in the Doctor Syn series of books by Russell Thorndike. The Coastguard was also responsible for giving assistance to shipwrecks.
Each Waterguard station was issued with a Manby mortar, which had been invented by Captain George William Manby in 1808. The mortar fired a shot with a line attached from the shore to the wrecked ship and was used for many years. This began the process through which the Coastguard assumed a life saving role. In 1821 a committee of inquiry recommended that responsibility for the Preventative Waterguard be transferred to the Board of Customs. The Treasury agreed and (in a memorandum dated 15 January 1822) directed that the preventative services, which consisted of the Preventative Water Guard, cruisers, and riding officers should be placed under the authority of the Board of Customs and in future should be named the "Coastguard". In 1845 the Coastguard was subordinated to the Admiralty.
In 1829 the first UK Coastguard instructions were published and dealt with discipline and directions for carrying out preventative duties. They also stipulated that, when a wreck took place, the Coastguard was responsible for taking all possible action to save lives, to take charge of the vessel and to protect property.
In the United States, the United States Coast Guard was created in 1915 by the merger of two other federal agencies. The first, the United States Revenue Cutter Service, was a maritime customs enforcement agency that also assumed a supporting role to the United States Navy in wartime. The second, the United States Life-Saving Service, was formed in 1848 and consisted of life saving crews stationed at points along the eastern seaboard. The Coast Guard later absorbed the United States Lighthouse Service and the Bureau of Navigation and Steamboat Inspection.
Among the responsibilities that may be entrusted to a coast guard service are:
During wartime, some national Coast Guard organisations might have a role as a naval reserve force with responsibilities in harbor defenses, port security, naval counter-intelligence and coastal patrols.
The Coast Guard may, varying by jurisdiction, be part of a country's military, a law enforcement agency, or a search and rescue body. For example, the United States Coast Guard is a military branch with a law enforcement capacity, whereas the United Kingdom's Her Majesty's Coastguard (HMCG) is a civilian organisation whose primary role is search and rescue. Most coast guards operate ships and aircraft including helicopters and seaplanes that are either owned or leased by the agency in order to fulfil their respective roles.