# Retaining Wall Block Calculator

> Estimates segmental (dry-stacked) retaining-wall blocks from the wall length and height and the block face size (courses × blocks per course plus waste), cap units for the top course, the compacted gravel base under the first course, the drainage-gravel zone behind the wall and the perforated drain pipe length. Planning estimate only.

- Calculator id: `retaining-wall-blocks` · Category: Construction & Home (`construction`) · Tool name: `estimate_retaining_wall_blocks`
- Canonical page: https://tttkmbb.com/construction/retaining-wall-blocks · This document: https://tttkmbb.com/construction/retaining-wall-blocks.md · JSON definition: https://tttkmbb.com/construction/retaining-wall-blocks.json

## Purpose

Estimates segmental (dry-stacked) retaining-wall blocks from the wall length and height and the block face size (courses × blocks per course plus waste), cap units for the top course, the compacted gravel base under the first course, the drainage-gravel zone behind the wall and the perforated drain pipe length. Planning estimate only.

**Use when:** You need to order concrete retaining-wall blocks, caps and the gravel for the base and drainage zone of a garden or landscape wall.

**Do not use when:** The wall is higher than about 1.2 m (4 ft), carries a slope or surcharge, or is terraced: it needs geogrid and engineering per the block manufacturer's tables. Mortared brick walls use brick; poured footings use concrete-footing.

## Input

| Parameter | Type | Unit | Required | Description |
| --- | --- | --- | --- | --- |
| `wall_length` | number | ft or m | required | Length of the wall face (ft or m, see unit). (> 0, max 10000) |
| `wall_height` | number | ft or m | required | Total block height including the buried first course (bury about 10 % of the height, at least 15 cm / 6 in) and excluding the caps. (> 0, max 100) |
| `unit` | enum: m \| ft |  | optional, default "ft" | Unit of the length inputs (m or ft). Lengths are reported in both units. |
| `block_length_in` | number | in | optional, default 12 | Face length of one block in inches (1 in = 25.4 mm); common units are 12 in and 18 in long. (> 0, max 48) |
| `block_height_in` | number | in | optional, default 4 | Height of one block in inches (4, 6 or 8 in). (> 0, max 24) |
| `block_depth_in` | number | in | optional, default 8 | Front-to-back depth of the block in inches; the base trench is 12 in wider than this. (> 0, max 48) |
| `cap_blocks` | boolean |  | optional, default true | Add a course of cap units (same length as the blocks) on top of the wall. |
| `base_depth_in` | number | in | optional, default 6 | Compacted crushed-stone base under the first course, in inches (6 in / 15 cm is the usual minimum). (min 0, max 24) |
| `gravel_backfill_depth_in` | number | in | optional, default 12 | Thickness of the clean-gravel drainage zone directly behind the blocks, in inches (12 in / 30 cm is standard). (min 0, max 48) |
| `waste_percent` | number | % | optional, default 5 | Extra material for cuts, breakage and offcuts, applied as a multiplier (1 + waste_percent/100). 5 % for straight walls; 10 % for curves and corners that need cut blocks. (min 0, max 50) |

## Output

| Field | Type | Unit | Description |
| --- | --- | --- | --- |
| `courses` | integer |  | ceil(wall_height / block_height). |
| `blocks_per_course` | integer |  | ceil(wall_length / block_length). |
| `blocks_before_waste` | integer |  | courses × blocks_per_course. |
| `total_blocks` | integer |  | ceil(blocks_before_waste × (1 + waste_percent/100)). |
| `cap_blocks_needed` | integer |  | blocks_per_course when cap_blocks is true, otherwise 0. |
| `base_gravel_yd3` | number | yd³ | wall_length × (block_depth + 12 in) × base_depth. |
| `base_gravel_m3` | number | m³ | Base gravel in cubic metres. |
| `backfill_gravel_yd3` | number | yd³ | wall_length × wall_height × gravel_backfill_depth. |
| `backfill_gravel_m3` | number | m³ | Backfill gravel in cubic metres. |
| `gravel_total_tonnes` | number | t | (base + backfill) × 1.6 t/m³. |
| `drainage_pipe_ft` | number | ft | Perforated pipe along the back of the base course = wall_length. |
| `drainage_pipe_m` | number | m | Drain pipe length in metres. |

## Formula

`courses = ceil(wall_height / block_height); blocks_per_course = ceil(wall_length / block_length); total_blocks = ceil(courses × blocks_per_course × (1 + waste/100)); caps = blocks_per_course; base_gravel = wall_length × (block_depth + 12 in) × base_depth; backfill_gravel = wall_length × wall_height × backfill_depth; tonnes = m³ × 1.6; drain_pipe = wall_length.`

Follows the usual segmental retaining-wall detail: a compacted crushed-stone base 6 in deep in a trench 6 in wider than the block on each side, a perforated drain pipe at the base behind the blocks and 12 in of clean gravel backfill; gravel volumes are as-placed (loose material compacts 10–20 %). Planning estimate only; check quantities against the supplier's coverage figures and local code before ordering.

## Data Sources

- Wikipedia – Retaining wall — https://en.wikipedia.org/wiki/Retaining_wall (reference, retrieved 2026-09-24)
- Wikipedia – Bulk density — https://en.wikipedia.org/wiki/Bulk_density (reference, retrieved 2026-09-24)

Data freshness: `static`. Deterministic formula with fixed constants; results never go stale. Inputs supplied by the caller determine the output.

## API

- `GET https://tttkmbb.com/api/v1/calculate/retaining-wall-blocks?wall_length=…&wall_height=…`
- `POST https://tttkmbb.com/api/v1/calculate/retaining-wall-blocks` with JSON body `{"inputs": {…}}`
- Response: unified envelope (`success`, `request`, `result.values`, `result.units`, `sources`, `freshness`, `timestamp`, `next_actions`, `links`); see https://tttkmbb.com/docs/response-format.md
- Schema: https://tttkmbb.com/api/v1/calculators/retaining-wall-blocks · OpenAPI operationId `estimate_retaining_wall_blocks` in https://tttkmbb.com/openapi.json
- Authentication: none. Rate limit: fair use, see https://tttkmbb.com/docs/rate-limits.md.

## MCP

- Server: `https://tttkmbb.com/mcp` (Streamable HTTP, JSON-RPC 2.0, no auth)
- Tool:  `run_calculator` with `{"calculator_id": "retaining-wall-blocks", "inputs": {…}}`

## Example

- 20 ft × 2 ft wall, 12 × 4 × 8 in blocks, caps, 6 in base, 12 in backfill, 5 % waste: inputs `{"wall_length":20,"wall_height":2,"unit":"ft","block_length_in":12,"block_height_in":4,"block_depth_in":8,"cap_blocks":true,"base_depth_in":6,"gravel_backfill_depth_in":12,"waste_percent":5}` → `{"courses":6,"blocks_per_course":20,"blocks_before_waste":120,"total_blocks":126,"cap_blocks_needed":20,"base_gravel_yd3":0.617,"base_gravel_m3":0.472,"backfill_gravel_yd3":1.481,"backfill_gravel_m3":1.133,"drainage_pipe_ft":20,"drainage_pipe_m":6.1}`
- 10 m × 0.8 m wall, 12 × 4 × 8 in blocks, caps, 5 % waste: inputs `{"wall_length":10,"wall_height":0.8,"unit":"m","waste_percent":5}` → `{"courses":8,"blocks_per_course":33,"blocks_before_waste":264,"total_blocks":278,"cap_blocks_needed":33,"base_gravel_m3":0.774,"base_gravel_yd3":1.013,"backfill_gravel_m3":2.438,"backfill_gravel_yd3":3.189,"drainage_pipe_ft":32.81}`

```
GET https://tttkmbb.com/api/v1/calculate/retaining-wall-blocks?wall_length=20&wall_height=2&unit=ft&block_length_in=12&block_height_in=4&block_depth_in=8&cap_blocks=true&base_depth_in=6&gravel_backfill_depth_in=12&waste_percent=5
```

## Limitations

The wall is higher than about 1.2 m (4 ft), carries a slope or surcharge, or is terraced: it needs geogrid and engineering per the block manufacturer's tables. Mortared brick walls use brick; poured footings use concrete-footing. Follows the usual segmental retaining-wall detail: a compacted crushed-stone base 6 in deep in a trench 6 in wider than the block on each side, a perforated drain pipe at the base behind the blocks and 12 in of clean gravel backfill; gravel volumes are as-placed (loose material compacts 10–20 %). Planning estimate only; check quantities against the supplier's coverage figures and local code before ordering. All values are computed from the formula above; no measurement or live data is involved.

## FAQ

**Should the first course be buried?**

Yes: bury about 10 % of the wall height, at least one course or 15 cm (6 in), so enter the total height including the buried course.

**Why is the base trench wider than the block?**

The compacted base extends about 15 cm (6 in) in front of and behind the block to spread the load and keep the base course from shifting, hence block_depth + 12 in.

**When do I need an engineer?**

Most block systems allow gravity walls up to about 1.2 m (4 ft) with level backfill; taller walls, slopes above the wall, driveways or terraces behind it need geogrid reinforcement designed from the manufacturer's charts or by an engineer, and many jurisdictions require a permit above 1 m.

## Related

- [Gravel Calculator](https://tttkmbb.com/construction/gravel.md) — Aggregate volume and weight for other layers.
- [Brick Calculator](https://tttkmbb.com/construction/brick.md) — Mortared brick wall quantities.
- [Concrete Footing Calculator](https://tttkmbb.com/construction/concrete-footing.md) — Concrete footing for a mortared wall.
