A port in Imperialism and Imperialism 2 is a facility built by an engineer on a coast or river. A port cannot be built on a hill or mountain. Every nation's capital city functions as a port. Army units need to be in a port if they are to invade using a beachhead; if the port is on a river where another nation controls the rivermouth, that may be impossible.
Each port costs five lumber and five cast iron. Fish need sea transport; so do any other commodities unless there is a road link to the capital. The port will collect up to four units of a resource from each tile in its radius, without needing the road or railway improvements that are needed for more than one unit elsewhere.