A dead battery is an all-too-common occurrence in a boat that sits idle most work weeks, and when it happens it nearly always spoils a planned day or weekend on the water. This unhappy circumstance can be avoided with the installation of a small solar panel. As an added benefit, absolutely nothing prolongs the life of a battery like keeping it fully charged. A battery charger can do the job for a boat on a trailer or at a dock, but there are risks to leaving an unattended boat plugged in. A solar panel avoids these. If your boat is on a mooring, a solar panel is the only practical choice for maintaining batteries at full charge.
Wet-cell batteries self-discharge at about 1% of amp-hour rating per day--more in hot weather, less when it's cold. So to float charge the battery, i.e., maintain a full charge, we need an equivalent charge rate. For a 100-amp-hour battery, that means a solar panel with a daily output of about one amp-hour.
Solar panels, however, are rated in watts. To determine the output current in amps, divide the watt rating by 15 — the approximate true output voltage of a typical solar panel. Thus a five-watt panel has a maximum output of about 0.33 amps. But rated output only occurs at high noon; the rest of the time, the panel puts out less. Expect average output to be the equivalent of about five hours of rated output per day. That makes the expected daily output of a five-watt panel about 1.65 amp-hours (5 x 0.33).
Allowing for recharging inefficiencies, this is still about 50% more than necessary to float a 100-amp-hour battery. A good rule of thumb is 3.5 watts per 100 amp-hours of battery capacity. But throw in an occasional sunless day, put blocking diodes in the circuit, and let the bilge pump run once in a while, and five watts will be about right. A small amount of extra capacity won't damage the batteries as long as you maintain the water level in them.
Whatever size panel you select, it should have at least 33 cells. Count them. Panels with fewer than 33 cells will have inadequate voltage to fully charge the battery. This assumes crystalline panels, which deliver the most output from the smallest package, but if you sail where overcast days outnumber sunny ones, you might consider a thin-film panel, as this type can have better low light output.
Solar panels give maximum output when they are perpendicular to the sun's rays, but since boat movement makes inclining the panel toward the sun less than a sure thing, it is almost always best to mount the panel horizontally. It should not be shaded by spars or antennas since even the thin shadow cast by a wire can drastically cut the output of the panel. Common locations are on radar arches and on top of T-tops and biminis. Deck mounting is just as effective as long as the chosen spot is shadow-free when the sun is high. Heat reduces output, so deck mounted panels should be raised enough for free air circulation beneath.
Wiring is essentially a matter of connecting the solar panel's positive terminal (or red lead) to the positive battery post, and the negative terminal to the negative battery post. Solar panels with a maximum output current of no more than about 1% of battery capacity don't require regulation, nor will you need a blocking diode to keep current from flowing back to the panel at night. What is essential is a fuse close to the battery.
Without a fuse, a short in the wiring is a dead short across the battery, with fire a likely consequence. If your boat has more than one battery (bank), you can maintain them with a dedicated solar panel wired to each bank, or you can use a single panel sized according to total battery capacity. If you are floating two battery banks with a single panel, insert diodes in both positive legs of the circuit to keep the batteries isolated. Low-loss Schottky diodes are best. The marked end of the diode (or the point of the arrow) goes on the battery side.
For additional information about solar panels, consult Sailboat Electrics Simplified.