Surface Waves
Waves on lakes, oceans, rivers and seas are powered by wind; the larger the surface of water over which the wind blows, the larger the waves that are eventually formed. As the surface waves enter shallower water, usually near a shoreline or shallow area of a river, three crucial developments occur: the waves slow down as they lose energy, they grow much higher and become more compact, so there is not as much distance between them as previously. The waves are said to be shoaling, in imitation of several fish gathering in one place.
Bar Formation
As the waves eventually break near shore, they encourage a shoreward momentum, which moves over the water beneath them that is flowing back towards the sea, known as backwash. Sand is transported by the backwash and dumped at the point where it meets the breaking wave. This constant depositing of sand, at a specific point offshore, eventually results in the formation of a sandbar, which is revealed only at low tide.
Sandspit
A sandspit (commonly shortened to "spit") is a type of sandbar that forms offshore. It runs perpendicular to the coastline, unlike conventional sandbars, which are parallel, and juts out from the shore like a pier. Its formation comes about owing to waves meeting the shore in a slanting fashion, leading to sediment being dumped in a jagged movement. The reasons behind the formation of a sandspit could be a sustained change in wind direction, or a river mouth applying resistance in the opposite direction.
River Sandbars
A river sandbar is formed differently than its coastal counterpart. River water carries silt, sand and clay in its narrow channel, but as it reaches the river mouth, the channel can no longer confine the water. It rapidly loses energy, and therefore its ability to carry its load. However, because sand is heaviest, it drops the sand near the mouth, and this leads to the formation of a river sandbar. They can sometimes grow to the extent that they completely block the river mouth, leading to flooding in the river's lower reaches.