A Common Misconception
When people new to sailing are asked how to make a sailboat sail, most people instinctively suggest to sail with the wind pushing the sail (running dead downwind). When sailing with the wind the force of the wind simply pushes on the sail. The sail mainly experiences aerodynamic drag as the aerodynamic flow is stalled.
A Sail Acts As An Aerodynamic Foil
Sailboats can actually sail faster than the wind because a sail can create lift just like an airplane wing. Most sailboats sail fastest on a reach. The propulsion from a sail follows Newton's third law of motion. When one body exerts a force on a second body, the second body simultaneously exerts a force equal in magnitude and opposite in direction on the first body.
How Lift On A Sail Works
The lift on a sail is created because wind is flowing faster on the leeward side of the sail, there is less pressure on the leeward side so a force to leeward is generated. This is where the force that heels the boat comes from and the reason that sailboats have foils in the water to counteract this force such as a keel or centerboard/dagger board The keel/dagger board and rudder are also shaped like a wing and create lift in the water. So the faster the boat is going the closer to the wind the boat can sail. Slow moving sailboats attempting to sail upwind will inherently slip sideways. If you try to sail a laser without the dagger board you won't be able to steer the boat and the boat will slip sideways.
The keel/dagger board, rudder and crew weight keep the boat from heeling over, balancing the forces which allows a sailboat to sail forward.