Mainly it’s just wind! Waves normally start out in deep water by wind and carry on to a beech until they reach more and more shallow water, peak and break.
The direction of the wind, whether a beach is a cove or protected by a harbour wall, the amount of wind recently and which part of the sea the beach is near will determine how many waves it gets and what types of waves!
Some of the places with the most waves are Australia, Hawaii and Indonesia, this makes sense as they’re exposed the Pacific (Australia and Hawaii) and the Indian ocean (Indonesia).
Other, less common waves such as tsunamis can happen due a seismic event. The 2004 Indian Ocean tsunami which mainly hit Thailand, Indonesia and Sri Lanka was caused by an earthquake out to sea.