The tide is the ocean answering to the sky. The Moon pulls hardest on the water directly beneath it, a little less on the rock of the Earth, less still on the far ocean — and that difference in pull, stretched across the planet, lifts a bulge on each side. Two bulges, turning under us: two high tides a day.
Here is the strange part. The Sun is 27 million times more massive than the Moon, and it hauls on the Earth with over 170 times the raw force. Yet the Moon runs the tide. Tidal force falls off not with distance but with distance cubed — so the small, close body overwhelms the vast, far one.
Distance matters more than mass. You are pulled most by what is nearest — not by what is largest.