You need appropriate licensing for the service in which you operate.
On the marine bands you need a ship station license (for the boat), which conveys a call sign and a Federal MMSI. The ship station license is good for 10 years between renewals. At least one person aboard should have a restricted radio operators permit (RP) for the operator. The RP is good for life. You can use your ship station license and RP anywhere in the world (consider the mind-boggling international agreements it took to make that happen!).
On the ham bands you need a ham license. Ham licenses are both a station license and an operator license in one document. You can use your ham license ON THE HAM BANDS anywhere in US territory, international waters, or in accordance with reciprocity agreements in some other countries. See International Operating
In an emergency you can use any service. An emergency means someone is at risk of dying. It does not include running short on Grey Poupon, making marina reservations, asking for weather information (unless you are in the midst of a hurricane or cyclone), or anything else that a reasonable person would consider a convenience.
The FCC licenses are issued for specific services and any given license is only good for operation in that service: marine, air, ham, GMRS, broadcast radio, broadcast TV, cell, WiFi, etc. In the US there are blanket waivers for many services including ship's radar and WiFi and the client side of cell.