Alligators are primarily freshwater animals and do not live in the ocean

An alligator

There are many things you may encounter when swimming in the ocean. Alligators probably aren’t one of them.

While alligators can tolerate salt water for a few hours or even days, they are primarily freshwater animals, living in swampy areas, rivers, streams, lakes, and ponds.

For more information:
Alligator, U.S. Geological Survey Southern Florida Information Access
American Alligator, U.S. Fish and Wildlife Service