The force of the wind on the sail and the counteracting force of the water on the hull and/or keel cause a sailboat to heel.
In the sketch, the "keel" of the sailboat has been placed on an outrigger some distance frm the centerline and is inclined at 45 degrees, instead of being mounted vertically on the hull as is normal. It is called a Bruce foil after its inventor.
If the boat is pushed sideways by the wind, the tendency for the wind to heel the boat is exactly cancelled by the force produced by the water on the foil .
The Theory
In the figure the wind is shown blowing right to left, acting on the sail. Note that the sail is inclined from the vertical although the boat is upright. The force generated by the wind is represented by the arrow labelled "wind force". The force acts at right angles to the sail, from right to left, at a downward angle due to the sail inclination.
Note: the force caused by the wind or water acting on a flat sail or leeboard is at right angles to the plane of the object, through its centroid. The centroid is the point at which a cardboard cutout of the sail or leeboard would balance. Since an actual sail is not perfectly flat this is only an approximation, but it is close enough for practical purposes.
Similarly, the force generated by the water against the inclined leeboard is represented by the arrow labelled "water force" acting from left to right at an upward angle. If the angles of the sail and foil are chosen correctly the wind and water cancel so the boat does not heel; this occurs when the wind and water forces meet at a point exactly over the center of the hull.
Early Trials
This is a rig I tried in 2004, on a small plastic kayak. The Bruce Foil and its outrigger is clearly visible. The entire thing is mounted on a small wooden deck attached to the boat by a strap around the belly and a couple of screws through the plastic deck. I built a foot-operated rudder for this rig.
The booms holding the sail retract and the whole sail collapses and can be wrapped around the mast. Then the outriggers can be unlocked and folded forward so the foil tucks up against the bow out of the way of paddling.
A more recent version has a slightly larger sail and folds umbrella-fashion, providing a more compact arrangement, but I don't have a photograph.
Experimental results
The rig worked well with zero heeling in a steady breeze. Gusts caused a brief heel with the boat returning to its upright condition almost immediately: when a gust hits the sail, momentarily there is no correcting force from the sail so the boat heels but as it starts to move sideways through the water the correcting force quickly acts on the leeboard to return the boat to upright.
The sailing performance was not great with such a small sail, although across the wind and downwind in a modest breeze a bow-wave quickly formed as the boat reached hull speed, which is as fast as can be expected. The hull speed of such a short boat is only about 4 knots but that is faster than can be achieved by paddling the boat shown.
Upwind performance was severely limited by sail area: a moderate breeze was required to be able to tack, paddle assistance often being required due to the small rudder, and the best it could do was hold itself in place, making virtually no progress upwind but not being blown downwind either, using 12-15 sq ft of sail. This was because of wind acting on the "crew", which is always downwind, causing enough leeway that the resulting path was simply backwards and forwards across the wind. Improvement would require a larger sail, or a boat permitting the "crew" more space to lie down out of the wind.
It is also noted that the leeboard was a simple, flat piece of plywood with no attempt at a more efficient shape.
The larger sail with the improved sail raising and lowering mechanism could be raised in approximately 30 seconds from the retracted paddling condition, and lowered from the sailing condition to paddling readiness in the same time. The entire rig weighed approximately 10 lb (4.5 kg).