Tides are created mainly by differences in the gravitational influence of the Moon and Sun across Earth, together with the motion of the Earth–Moon system. Although the Sun is far more massive, the Moon is much closer, so its tide-generating effect is stronger. The Sun still matters: its tide-generating influence is roughly half the Moon’s.
In a simplified model, the Moon’s pull is strongest on the side of Earth closest to it and weaker on the far side. That difference, combined with the inertia of the Earth–Moon system, produces two broad tidal bulges on opposite sides of the planet. As Earth rotates relative to those bulges, coastlines move through changing water levels.
The two-bulge model is a useful starting point, not a complete map of real tides. Continents interrupt the water’s path, while ocean-basin shape, depth, friction, and local coastal geography reshape the astronomical signal. That is why a station-specific prediction is more useful than assuming every coastline follows the same simple cycle.
Source: NOAA Tides and Water Levels