There have always been customs and border officials, under various agency names and titles, darting around the United States checking this port here and that part of the border there. However their numbers were small, the borders were mostly unprotected, and their overall effectiveness was spotty. If we count the US has having begun in 1776, then the period of 1776 to 1790 was the period of greatest open borders. Customs Houses predate the U.S. as a country, and we basically took over the existing British ones after independence. Any port that was capable of receiving ocean-going ships has always had a Customs House, and it was pretty much a required but honor-based self-reporting system that goes back to the Middle Ages.. Upon arriving in a port, a ship Captain's first task upon disembarking was to immediately report to the Customs House to declare his cargo and pay any import duties or taxes, and then to the Harbormaster to pay any port fees. Now this could all be avoided if you wanted to turn smuggler and just run a few miles up the coast and dump your load there, but this presented its own set of problems. You had to have accomplices ashore to help you, a quiet buyer for your goods, and a way of communicating with both of them. You frequently didn't have a harbor with water deep enough to properly moor your vessel and it was frequently just a random quiet stretch of beach. This meant you had to stand offshore and transfer your cargo into smaller boats and make numerous trips. This was a long laborious task, with increased visible exposure time and then inevitably some honest citizen or fisherman somewhere along the coast would eventually spot you and start passing the word back to the closest port. Once they had your vessel's name, your ship was on a blacklist and you couldn't put into a reputable port at all anymore without being imprisoned, or even hung. Nevertheless, overall enforcement was lax, and smuggling was still rampant throughout all 13 colonies. This started to dial way down though in 1790 when Alexander Hamilton, as the then Secretary of the Treasury, created the Revenue Cutter Service, the forerunner of today's US Coast Guard. Ten vessels were initially ordered and constructed. Two cutters were to be assigned to the coasts of Massachusetts and New Hampshire; one for Long Island Sound; one for New York; one for the Bay of Delaware; two for Chesapeake Bay, one for North Carolina; and one for Georgia. These vessels hit the high seas, and the U.S. has never been without some level of border protection ever since. Interestingly, everyone tends to obsess about our southern border or the coasts, but our real exposure is north. The U.S.- Canada border is the longest piece of undefended border in the world, coming in at over 5500 miles long. Despite checkpoints on the roads, most of the border is just wilderness that can be walked across openly, though not legally and not necessarily without detection.