Rockport is a town in Essex County, Massachusetts, United States. The population was 6,952 at the 2010 census. Rockport is located approximately 40 miles (64 km) northeast of Boston at the tip of the Cape Ann peninsula. It is considered part of the North Shore Massachusetts and is directly east of Gloucester. Rockport is surrounded on three sides by the Atlantic Ocean.