Ocean Erosion
One of the chief advantages of seawalls is that they protect human settlements from the myriad ways in which oceans slowly erode the coastal lands upon which the structures are built. The regular pounding of waves and tides constantly breaks down coastal land. Sand is formed as a part of this process, whereby stones are slowly rubbed together and broken down into smaller and smaller pieces. Oceanside property is highly valued, however, and seawalls are one way to protect that valuable property from unpredictable erosion.
Lake Erosion
However, oceans are not the only bodies of water that human settlements must be protected from. Lakes also cause erosion, though typically in different ways than oceans. Lakes, for example, are far more susceptible to freezing than oceans are. Water that freezes in the cracks of rocks can split the rocks, eroding banks. Similarly, large chunks of ice rubbing against banks can cause erosion. Seawalls are often constructed on lakes to help forestall the slow march of nature.
Marinas
Some seawalls are constructed to help protect marinas from the destructive power of the ocean. Natural land formations that give partial protection to a marina may be made far more effective with the addition of large rocks or cement walls. Boats are not damaged by tides and the waves on a calm day, but storms and high winds can cause significant damage to a boat tied to a dock, and seawalls help to protect from that.
Tsunamis
Seawalls are used to protect land from much rarer destructive forces generated by the sea, such as tsunamis. Tsunamis are most often linked with earthquakes and can be massively destructive, both in terms of human settlements and lives. The 2011 earthquake off the coast of Japan, for instance, created a massive tsunami. Many coastal settlements in Japan had built seawalls, some of which successfully protected those settlements and some of which were too small to offer much protection. There is no doubt, however, that seawalls built to protect from tsunamis save a great many lives.