The deep-water berths at Bantry Bay and Berehaven Harbour were important from as early as the Nine Years' War and Siege of Dunboy in 1602, through the United Irishmen Rebellion and French Armada landings in the 1790s. The defences remained critical to support the Bantry Bay (anti-submarine) Naval Air Station during World War 1, and Berehaven "Treaty Port" was used by the Royal Navy fleet until it was relinquished in 1938 under the terms of the Anglo-Irish Treaty.