Laying out real modules
Panels never cover an entire roof. Wind, fire access and installers all need free space at edges and ridges. Chimneys and skylights cut holes in the grid, and module sizes are fixed. On flat roofs, tilted rows must also be spaced to avoid mutual shading. For these reasons the tool places actual modules instead of just dividing square metres.
Pitched roofs. A depth taken from a floor plan or from the ground is converted into true length along the slope: plan depth ÷ cos pitch. At 35° the slope is 22% longer than the plan. Eave, ridge and side setbacks are removed, and modules plus clamp gaps are packed three ways: every module portrait, every module landscape, or a mix in which portrait rows end with one landscape row across the remaining strip. The layout with the most modules is kept. The gable option repeats it on the opposite face, which has its own yield.
Flat roofs. Modules stand in tilted rows. Rows facing the equator are spaced so the row behind stays clear of shade at solar noon on the year’s shortest day at your latitude. In east–west layouts, rows are paired back to back and a service path separates each pair. Portrait and landscape mounting are both tried and the denser result is kept.
Obstructions count at 1.5 times their area, since each one breaks up rows and columns. Annual energy is system size multiplied by your specific yield, and added roof load follows from module plus racking weight.
Geometry
Definitions: m is the module side that runs up the tilt, β the row tilt, and α the sun’s elevation at noon on the winter solstice.
Example: a south roof of 10 m × 5 m at 35°
The preset roof has a 10 m eave line, a plan depth of 5 m and a 35° pitch. Measured along the slope it is 6.1 m deep, giving 61 m² of surface. Setbacks of 0.3 m (eaves), 0.4 m (ridge) and 0.4 m (each gable end) leave a 9.2 × 5.4 m rectangle.
Take 430 W modules measuring 1.722 × 1.134 m and 20 mm clamp gaps. Laid in portrait, 3 rows of 7 give 21 modules; in landscape, 4 rows of 5 give 20. A mixed layout cannot add another row. The 1 m² chimney removes one module, so you end up with 20 panels = 8.6 kWp. At 1,200 kWh/kWp that means about 10,300 kWh a year. Roughly 64% of the roof surface is covered, with a load of around 14 kg/m².
Comparing panel types teaches something less obvious. A marginally bigger 450 W module fills the same 20 slots and reaches 9.0 kWp, but the large 550–700 W formats fit badly on this small roof and end up with lower total power.
Understanding the numbers
- Panel count and layout (rows × columns, portrait or landscape): the drawing an installer would produce.
- Usable area after setbacks: shows how much roof the rules remove, often 20–30% on small roofs.
- Power density (Wp per m² of roof) is a yardstick across roofs and layouts. Typical results: 120–160 Wp/m² for pitched roofs, 80–110 Wp/m² for south-facing rows on flat roofs, and 120–150 Wp/m² for east–west flat-roof layouts.
- Added roof load: an early figure for the structural check.
Typical values
| Roof | Typical usable share | Modules (430 W) per 10 m² of roof | Wp per m² roof |
|---|---|---|---|
| Simple pitched roof, few obstacles | 70–85% | 3.5–4.5 | 140–180 |
| Pitched roof with dormers/skylights | 50–70% | 2.5–3.5 | 100–140 |
| Flat roof, south rows at 15° (45–50° lat.) | 40–50% module cover | 2–2.5 | 85–110 |
| Flat roof, east–west at 10° | 55–70% module cover | 3–3.5 | 120–150 |
Fitting more panels
- Try portrait, landscape and mixed rows. One extra landscape row in a leftover strip is common.
- Compare module formats, not just watts. On small or awkward roofs, compact 108-cell modules often yield more kWp than big 144-cell or 210 mm formats.
- On flat roofs, pick east–west when space is the limit and south-facing rows when yield per module matters more.
- Learn your setback rules. Fire-access and wind-zone rules vary a lot; a few US jurisdictions give up a third of a small roof to them.
- Afterwards. To see whether the count meets your needs, open how many solar panels. Output can be estimated with the solar panel calculator, and the string sizing calculator covers the wiring.
Limitations
All roofs are treated as rectangles. Break hips, valleys, dormers and irregular outlines into rectangles and run them one at a time. Obstructions enter as a statistical allowance, not at their real position. Shading from chimneys, trees or neighbouring buildings is not modelled, nor are partial rows shifted around obstacles. Row spacing on flat roofs uses a solar-noon rule; at high latitudes designers often tolerate a little winter shade in exchange for extra modules. Treat the roof load as indicative only; before installing, have the structure assessed for snow and wind.
Method & assumptions
Pitched roofs first. Slope depth is plan depth ÷ cos(pitch). Subtract setbacks to get the usable rectangle: length − 2 × side setback across, slope depth − eave − ridge setbacks down. Modules (with clamp gaps) are packed in portrait rows, in landscape rows, or in mixed rows, where portrait rows come first and landscape rows fill the strip left over. The layout that holds most panels is chosen.
Flat roofs next. Tilted rows facing the equator at angle β must be spaced at d = m·cos β + m·sin β ÷ tan α. In this formula, m is the module's dimension up the slope, and α is the noon sun elevation at the winter solstice (90° − latitude − 23.44°). East–west layouts pair rows back-to-back and leave a maintenance path between pairs. Any obstruction removes ⌈1.5 × area ÷ module area⌉ modules, and kWh = kWp × specific yield.
Frequently asked questions
How do I count the panels that fit on a roof?
How much roof does a 6 kW solar system need?
Should panels be portrait or landscape?
What spacing do flat-roof panel rows need?
Do east-west panels on a flat roof make sense?
Is my roof strong enough for solar panels?
Sources & references
- International Fire Code (IFC 2021) Section 1205 — Solar photovoltaic power systems (roof access and pathways)
- NREL — Rooftop Solar Photovoltaic Technical Potential in the United States (roof suitability and packing assumptions), NREL/TP-6A20-65298
- Eurocode 1 (EN 1991-1-3/-1-4) — snow and wind actions on roofs
- European Commission JRC — PVGIS (yield per kWp for any orientation)
Embed this calculator
Free for bloggers, installers, schools and NGOs. Copy the snippet below and it stays current by itself.