Decking calculator
A 12 by 10 foot deck with 5.5 inch boards and a 1/8 inch gap takes 22 boards, 264 linear feet in all. Enter your deck and boards to know exactly what to ask for at the lumber yard. Free in your browser.
- Free
- Runs in your browser
- No sign-up
- Your data stays on your device
Run — free
Worked example
- Length
- 12
- Width
- 10
- Board width
- 5.5
- Gap
- 0.125
- Board width ft
- 0.4583333333
- Gap ft
- 0.0104166667
- Pitch in
- 5.625
- Pitch ft
- 0.46875
A rectangular deck is bought as boards, not as a single sheet of lumber: you need a whole-board count across the width and a total linear-footage figure to take to the lumber yard or composite dealer. This decking calculator takes the deck length and width in feet, the face width of one decking board in inches, and the gap spacing in inches, then returns how many boards you must buy and the total linear feet those boards represent. Boards run along the length; they pack across the width with a gap between adjacent faces and no trailing gap after the last board.
How board count and total linear feet are computed
Treat the deck as a rectangle whose boards run along the length and whose faces pack across the width. Convert the inch inputs to the same scale as the deck: board face width and gap stay in inches, and the width in feet is multiplied by twelve so the covering problem is entirely in inches. Because the last board has no trailing gap, n boards and n minus one gaps must cover the width, which rearranges to n equals (width in inches plus gap) divided by pitch.
A twelve-by-ten-foot deck with five-and-a-half-inch boards and a one-eighth-inch gap has a pitch of 5.625 inches, an exact count of about 21.36, a purchase count of twenty-two boards, and 264 linear feet. The path is deterministic floating-point arithmetic with no random seeds, no wall-clock timestamps, and no network. Zero gap is a legal butt-tight layout; a zero or negative board width is not, because pitch would vanish or reverse and the count would be undefined.
Where a decking calculator earns its keep
Homeowners planning a weekend rectangle reach for a decking calculator when the lumber yard asks how many boards and how many linear feet, not how many square feet of abstract area. Typing twelve by ten feet, a five-and-a-half-inch face, and an eighth-inch gap yields a count you can compare against a unit price per linear foot without opening a spreadsheet of mixed units.
Remodelers choosing between a 5.5-inch wood face and a 5.25-inch composite face re-run the same length and width to see how the count and linear footage move when the pitch changes; that is a materials decision, not a waste-percent decision. Contractors bidding a simple rectangular deck pin the goldens in tests so a takeoff script and a phone check never disagree on whether twenty-one boards cover ten feet. Trade-school modules on exterior carpentry can freeze the twelve-by-ten, 5.5-inch, 0.125-inch case because the arithmetic is deterministic.
This landing is the search for decking as linear material: board count and total linear feet from length, width, face width, and gap. An area-plus-stock-length-plus-waste calculator answers a different query and should not share this page.
What you can do with it
Wood versus composite face width
Re-run the same rectangle with a 5.5-inch wood face and a 5.25-inch composite face to see how pitch changes the board count and linear footage.
Contractor bid linear footage
Pin a 12-by-10-foot goldens case in a takeoff script so the phone check and the bid line agree on whole boards and linear feet.
FAQ
How does the decking calculator count boards?
Boards run along length (feet) and pack across width (feet).
Does the last board include a gap after it?
A zero gap is allowed for a butt-tight layout.
How many boards do I need for a 12 x 10 foot deck?
With 5.5 inch boards and a 0.125 inch gap, each board plus its gap takes 5.625 inches, so 22 boards cover the 10 feet. Running 12 feet each, that is 264 linear feet.
Should I enter the nominal or the actual board width?
The actual face width you measure, not the size printed on the stamp. Common nominal 6 inch decking is 5.5 inches on the face; a 5.25 inch composite board changes the count and the footage.
How much does the last board stick out past the deck?
The result shows how far the stack of boards goes beyond your width. In the 12 by 10 foot example it is 3.625 inches, so you can decide whether to rip the last board lengthwise.
Related tools
For developers — API access
Everything on this page is available programmatically. This section is for teams who want to wire it into their own systems; everyone else can just use the tool above.
API endpoint
Prefer to automate it? One authenticated POST creates the task; the result comes back by webhook or a signed link. The same capability also runs here on the web, by email and from Telegram — and soon from our app too.
Call it from your stack
curl -X POST https://api.kit.forhosting.com/build/decking \
-H "Authorization: Bearer $KIT_KEY" \
-H "Content-Type: application/json" \
-d '{"length":12,"width":10,"board_width":5.5,"gap":0.125}'const res = await fetch("https://api.kit.forhosting.com/build/decking", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.KIT_KEY}`,
"Content-Type": "application/json"
},
body: JSON.stringify({
"length": 12,
"width": 10,
"board_width": 5.5,
"gap": 0.125
})
});
const { task_id } = await res.json();import os, requests
res = requests.post(
"https://api.kit.forhosting.com/build/decking",
headers={"Authorization": f"Bearer {os.environ['KIT_KEY']}"},
json={
"length": 12,
"width": 10,
"board_width": 5.5,
"gap": 0.125
},
)
task_id = res.json()["task_id"]<?php
$res = file_get_contents("https://api.kit.forhosting.com/build/decking", false, stream_context_create([
"http" => [
"method" => "POST",
"header" => "Authorization: Bearer " . getenv("KIT_KEY") . "\r\nContent-Type: application/json",
"content" => '{"length":12,"width":10,"board_width":5.5,"gap":0.125}',
],
]));
$task = json_decode($res, true);body := bytes.NewBufferString(`{"length":12,"width":10,"board_width":5.5,"gap":0.125}`)
req, _ := http.NewRequest("POST", "https://api.kit.forhosting.com/build/decking", body)
req.Header.Set("Authorization", "Bearer "+os.Getenv("KIT_KEY"))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)Example request
{
"length": 12,
"width": 10,
"board_width": 5.5,
"gap": 0.125
}Example response
{
"task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
"type": "build.decking",
"status": "queued",
"_links": {
"result": "/tasks/tsk_…/result"
}
}The API is asynchronous: the call returns a task_id immediately and the result arrives by webhook. Polling is capped at 1 req/s per task.
Pricing
Published price — no tokens, no invented credits. A failed task is never charged.
Errors
| HTTP | Code | Meaning |
|---|---|---|
401 | unauthorized | Missing or invalid API key. |
402 | insufficient_balance | Your balance doesn't cover the task price. |
404 | unknown_type | That task type doesn't exist. |
429 | rate_limited | Too many requests. Use the webhook instead of polling. |
Technical notes
A non-positive board width is rejected with invalid_input so a typo never invents an infinite count. The same pure arithmetic powers the free browser tool and the API path, so a Saturday sketch matches the line a purchasing script posts later.
How board count and total linear feet are computed
The pitch of one board plus its following gap is board_width plus gap. That exact ratio is boards_exact; the purchase quantity board_count is the ceiling of that ratio, so a fractional leftover still costs a whole extra board. Total linear feet is then board_count times the length in feet, because each board spans the full run. Coverage width is the laid-up stack of those twenty-two faces and twenty-one gaps; extra_width_in is how far that stack extends past the target width so you can decide whether to rip the last board.
What you send, which units apply, and how errors behave
Non-positive length or width and a negative gap fail the same way. Send four required finite numbers. length is the deck dimension in feet along the boards; each purchased piece is assumed to span that run, so linear footage is count times length. width is the deck dimension in feet across the boards, the direction you fill with faces and gaps. board_width is the actual face width in inches, not the nominal size on the stamp: common five-quarter by six stock is 5.5 inches on the face, and a five-and-a-half-inch composite plank is entered the same way. gap is the intended spacing in inches between adjacent faces; one-eighth of an inch is 0.125, a quarter inch is 0.25, and zero is allowed when boards are butted. Missing fields, empty strings, non-numeric text, NaN, and Infinity fail with invalid_input naming the field and are not charged. A zero or negative board_width fails with a message that board width must be a positive number. On success the JSON echoes the cleaned inputs, the converted board_width_ft, gap_ft, pitch_in, and pitch_ft, the rectangle area deck_area_ft2, boards_exact, the whole board_count, total_linear_feet, coverage_width_ft, extra_width_in, plus a unit_note, a formula string, and method decking_boards_across_width so logs can document the algorithm. API pricing is the published base of $0.002 per successful item; validation failures do not consume prepaid balance.
Where a decking calculator earns its keep
Because this capability is a pure parse engine, API pricing is the published base of $0.002 per successful item and failed validation does not consume balance. Keep requests small, pin board_count and total_linear_feet in tests, and you get a reproducible takeoff for quotes, purchase orders, and edge workers without standing up a CAD kernel of your own.
Integration use cases
Weekend rectangular deck takeoff
Enter length and width in feet plus a 5.5-inch board and an eighth-inch gap to get board_count and total_linear_feet before you visit the lumber yard.
Technical questions
What units do length, width, board_width, and gap use?
length and width are feet. board_width and gap are inches (for example 5.5 and 0.125). The response converts the inch fields to feet for pitch_ft and reports total_linear_feet in feet.
What happens if board width is zero or negative?
The task fails with invalid_input. A non-positive board_width would make pitch vanish or reverse, so the calculator refuses to invent a board count and is not billed.
What does the decking calculator cost?
The browser tool is free. API requests use prepaid balance at $0.002 per successful call; invalid input is not billed.