ForHosting KIT · Education

Classroom spacing calculator

Find out how many students fit in a room at the spacing you need: a 10 by 8 floor with each learner claiming a 2 by 2 square seats 20, in 5 rows of 4 seats. Free in your browser.

  • Free
  • Runs in your browser
  • No sign-up
  • Your data stays on your device
Use it from WebAPIEmailTelegramApp soon
If you enter
Length
10
Width
8
Spacing
2
You get
Area
80
Cell area
4
Layout rows
5
Seats per row
4

Enter the clear floor plate after you have already subtracted the teacher desk strip, fixed cabinets, and door swings you will not sit in, then enter the on-center spacing each learner needs—one and a half metres for distancing, a typical desk pitch, or any other positive distance in the same linear unit as the room. The tool tiles a rectangular square grid, reports how many layout rows fit along the length, how many seats fit in each row along the width, and multiplies those two integers into a maximum capacity.

How student capacity is derived from room size and spacing

A rectangular classroom is modeled by two strictly positive linear dimensions: length is the axis along which layout rows stack, typically from the teaching wall to the back of the room, and width is the axis of a single row of seats, typically from one side wall to the other. Required spacing per student is the side of a square cell each learner claims on that floor plate—the same idea as on-center desk pitch or a social-distance circle inscribed in a square.

Along the length you can fit floor of length divided by spacing whole rows; along the width you can fit floor of width divided by spacing whole seats; maximum capacity is the product of those two integers. Area is length times width and cell area is spacing squared, so used area is capacity times cell area and unused area is the remainder of the rectangle that the grid did not fill. Length, width, and spacing must use one consistent unit: metres with metres, feet with feet, inches with inches.

The calculator never converts units; it only needs the dimensionless ratios of each room side to the spacing. Spacing must be strictly positive because zero spacing would imply infinitely many students and negative spacing has no meaning on a grid. Length and width must also be positive; a zero-area room is not a classroom.

When the room is smaller than one cell on either axis the capacity is zero rather than an error, which is physically honest. The response does not consult fire-code occupant loads, furniture catalogs, staggered rows, or hexagonal packing—those are design choices you apply by changing the spacing you enter or by subtracting aisles from the dimensions before you call.

Reopening and distancing plans

Principals enter usable length, width, and a distancing pitch to see maximum capacity and how many layout rows of desks the room can hold.

What is a layout row in this calculator?

The compact layout field prints those two integers as rows × seats.

What if spacing or a room dimension is zero or negative?

Spacing, length, and width must all be strictly positive; zero or negative values cannot define a seating cell or a classroom.

Do length, width, and spacing have to use the same units?

Yes. The calculator never converts units. Use metres with metres, feet with feet, or any other single linear unit for all three numbers so the ratios stay dimensionless and correct.

What does the classroom spacing calculator cost?

The browser tool is free and runs locally.

Does the calculator follow fire-code or occupancy rules?

No. It only fits a square grid of seats into the floor you enter. Fire-code loads, furniture, staggered rows and aisles are your call: subtract aisles from the measurements or enter a larger spacing before you calculate.

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.

POSThttps://api.kit.forhosting.com/edu/classroom-spacing

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.

curl -X POST https://api.kit.forhosting.com/edu/classroom-spacing \
  -H "Authorization: Bearer $KIT_KEY" \
  -H "Content-Type: application/json" \
  -d '{"length":10,"width":8,"spacing":2}'
{
  "length": 10,
  "width": 8,
  "spacing": 2
}
{
  "task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
  "type": "edu.classroom_spacing",
  "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.

Per request$0.002

Published price — no tokens, no invented credits. A failed task is never charged.

HTTPCodeMeaning
401unauthorizedMissing or invalid API key.
402insufficient_balanceYour balance doesn't cover the task price.
404unknown_typeThat task type doesn't exist.
429rate_limitedToo many requests. Use the webhook instead of polling.

Zero or negative spacing, length, or width is rejected with invalid_input instead of inventing infinitely many desks.

How student capacity is derived from room size and spacing

Leftover strips that are shorter than one full spacing become unused_length and unused_width rather than a partial student, which matches the geometry of a full cell that does not fit. On success the tool echoes rounded length, width, and spacing, then publishes layout_rows, seats_per_row, max_capacity, a compact layout string, leftover strips, formula, message, and ordered substitution steps you can audit by hand.

How to call the API and what comes back

String forms of numbers are accepted when they match a strict finite numeric pattern; unit suffixes, thousand separators, or free text fail validation. Prefer sending numbers rather than pre-formatted strings when you control the client; when you must send strings, avoid unit labels that would fail the finite-number pattern. Round-trip checks are easy: recompute floor of length over spacing, floor of width over spacing, multiply, and confirm the published capacity and leftover strips match. Send a JSON body with three required fields: length (aliases room_length, classroom_length, depth, L), width (aliases room_width, classroom_width, W), and spacing (aliases student_spacing, seat_spacing, distance, gap, S). All three must be finite positive numbers within the published absolute range so the products, ratios, and leftover strips remain finite in IEEE double precision on the Worker and in the browser. On success the response echoes rounded length, width, and spacing, sets area to length times width, cell_area to spacing squared, layout_rows to the non-negative integer floor of length over spacing, seats_per_row to the non-negative integer floor of width over spacing, max_capacity to their product, layout to a compact rows-by-seats string, unused_length and unused_width to the leftover strips, used_area and unused_area to the filled and leftover floor, formula to the published identities, message to a short English summary, and steps to an ordered substitution log. Failed validation—missing fields, non-finite numbers, zero or negative spacing, non-positive room dimensions, or values outside absolute limits—returns invalid_input and is never charged. Pricing is a flat $0.002 per successful request with unit item. Swap length and width if you want the opposite orientation; the product stays the same while layout_rows and seats_per_row trade places.

Practical tips, limits, and related searches

Measure the clear seating rectangle after subtracting the teaching wall strip, storage, and any aisle you will not occupy, then choose a spacing that matches your desk pitch, distancing policy, or exam layout—one and a half metres, two feet, or a custom pitch are all valid as long as the three numbers share a unit. Keep dimensions inside the published absolute range so counts cannot overflow into non-finite results the solver must reject. Prefer this capability when you already know usable length, usable width, and target square-grid spacing and only need an integer capacity plus a row layout; if your source is a single area and a square-metre-per-person rule, convert that rule into a linear spacing yourself or use an area-only plant-style count, which will not report layout rows. If unused_length or unused_width is large, either reduce spacing slightly so more whole cells fit, enlarge the room, rotate the grid by swapping length and width for a different row count, or accept the remainder as a circulation strip; this calculator never adds a partial student. When teaching or writing tests, pair an exact multiple (length ten, width eight, spacing two → five layout rows, four seats per row, twenty students) with a remainder case that leaves leftover strips, and include a deliberate zero or negative spacing to prove the invalid_input path. This landing targets people searching for a classroom spacing calculator, how many students fit in a room, seating capacity from room dimensions, layout rows for desks, or student spacing online; it is not a fire-code occupant-load estimator, not a furniture CAD placer, not an HVAC sizing tool, and not a credit-hour or course-load calculator. Failed tasks that return invalid_input do not consume prepaid balance, which keeps exploratory scripts cheap when you deliberately send zero spacing to verify error handling. School business officers, campus planners, and SaaS facilities tools can all call the same endpoint for reproducible take-offs without sharing a spreadsheet formula that drifts between browsers.

Exam and furniture layouts

Exam officers and furniture vendors feed room size and desk pitch into the API and attach capacity, rows, and leftover strips to a transparent seating plan.

Golden fixtures for campus apps

Developers generate known-good exact and remainder cases plus deliberate zero-spacing rejections for unit tests and CI.

How many students fit in a classroom at a given spacing?

On a square on-center grid, layout_rows = floor(length / spacing), seats_per_row = floor(width / spacing), and max_capacity is their product. Example: length 10, width 8, spacing 2 → 5 rows × 4 seats = 20 students.

Read the full KIT documentation →