Prism volume calculator
Enter the area of the base and the height of a right prism and get its volume: a base of 12 and a height of 5 hold 60 cubic units, whatever the shape of the base. Free in your browser.
- Free
- Runs in your browser
- No sign-up
- Your data stays on your device
Run — free
Worked example
- Base area
- 12
- Height
- 5
- Volume
- 60
- Prism type
- right
A right prism is a solid with two congruent parallel polygonal bases joined by rectangular lateral faces that stand perpendicular to those bases. Its volume is the product of the base area and the height between the bases: V equals B times h. That single rule covers triangular, rectangular, pentagonal, hexagonal, and irregular polygonal bases once you already know the area of one base. Students meet the formula in middle-school solid geometry, then reuse it in high school for composite solids and surface-to-volume checks. Engineers and packaging designers need the same product when a drawing lists floor area and extrusion height rather than a full mesh.
What a right prism is and how volume is defined
In Euclidean solid geometry a prism is a polyhedron with two parallel congruent polygonal bases and lateral faces that are parallelograms. When every lateral edge is perpendicular to the base planes, the prism is called right: the lateral faces become rectangles and the height is simply the common length of those edges as well as the orthogonal distance between the bases. The volume measure stacks infinitesimal slices congruent to the base along that height, which algebraically collapses to the elementary product V equals B times h.
Search intent clusters around phrases such as prism volume calculator, right prism volume, base area times height, and V equals B h prism formula. People want a numeric cubic measure they can check against a homework key, a bill of materials, or a packing estimate, not only a verbal definition of the solid.
What you can do with it
Homework and exam right-prism drills
Students and graders confirm V=B·h for right prisms from base area and height, including clear rejection when either value is negative.
FAQ
Is the prism volume calculator free?
The browser tool runs free on your device.
Does this work for triangular or hexagonal bases?
Yes, as long as you supply the base area of that polygon and the prism height. The formula does not depend on the number of sides once base area is known.
What is the formula for the volume of a prism?
Multiply the area of one base by the height between the two bases. A prism with a base area of 12 and a height of 5 has a volume of 60, in the cube of the length unit you used.
What units does the volume come out in?
In the cube of whatever units you used, as long as they match. A base in square centimetres and a height in centimetres give cubic centimetres, with no conversion in between.
Can I use it for a leaning prism?
Only if you enter the perpendicular distance between the two bases as the height. The slanted side edge of a leaning solid is longer than that distance and would overstate the volume.
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/geom/prism-volume \
-H "Authorization: Bearer $KIT_KEY" \
-H "Content-Type: application/json" \
-d '{"base_area":12,"height":5}'const res = await fetch("https://api.kit.forhosting.com/geom/prism-volume", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.KIT_KEY}`,
"Content-Type": "application/json"
},
body: JSON.stringify({
"base_area": 12,
"height": 5
})
});
const { task_id } = await res.json();import os, requests
res = requests.post(
"https://api.kit.forhosting.com/geom/prism-volume",
headers={"Authorization": f"Bearer {os.environ['KIT_KEY']}"},
json={
"base_area": 12,
"height": 5
},
)
task_id = res.json()["task_id"]<?php
$res = file_get_contents("https://api.kit.forhosting.com/geom/prism-volume", false, stream_context_create([
"http" => [
"method" => "POST",
"header" => "Authorization: Bearer " . getenv("KIT_KEY") . "\r\nContent-Type: application/json",
"content" => '{"base_area":12,"height":5}',
],
]));
$task = json_decode($res, true);body := bytes.NewBufferString(`{"base_area":12,"height":5}`)
req, _ := http.NewRequest("POST", "https://api.kit.forhosting.com/geom/prism-volume", body)
req.Header.Set("Authorization", "Bearer "+os.Getenv("KIT_KEY"))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)Example request
{
"base_area": 12,
"height": 5
}Example response
{
"task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
"type": "geom.prism_volume",
"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
This capacity accepts non-negative finite base_area and height, rejects negative measures with a clear invalid_input error, and returns volume plus the formula as structured JSON.
What a right prism is and how volume is defined
Delivering volume, base_area, height, prism_type, and formula as JSON makes the result easy to paste into notes, diff in automated tests, or feed into a larger pipeline without reimplementing the product in every language you teach or deploy across lesson platforms, CAD helpers, and packaging tools that already know base area and extrusion height from an earlier step.
How this calculator validates input and applies V equals B times h
You may use any consistent unit system; if base area is in square centimeters and height in centimeters, volume is in cubic centimeters without conversion inside the engine. Do not pass a slanted lateral edge as height for a leaning solid unless you have already projected it to the orthogonal distance between bases; this capacity is scoped to the right-prism model where height is perpendicular by definition. Send a JSON body with two required fields: base_area and height. Both must be finite numbers, supplied as JSON numbers or numeric strings. The engine rejects empty, missing, or non-finite values with an invalid_input message that names the bad field. Negative measures fail explicitly: a negative base_area or height is not a valid solid dimension under this contract and raises an error before any volume is returned. When both measures pass, volume is the product of base_area and height. Results are rounded to a stable decimal precision so the same input always yields the same JSON across JavaScript engines. The response echoes the validated base_area and height, tags prism_type as right, and records the formula string V equals B times h for transparency in lesson materials.
Practical use, limits, pricing, and delivery channels
Use the browser tool when you want an immediate right-prism volume while checking solid-geometry homework, verifying a column or packing box from base area and height, or confirming a packaging sketch without installing a computer-algebra system. There is no language model, no external geometry service, and no randomness, so the capacity is safe to pin in continuous-integration checks and reproducible lesson materials. Remember the contract limits: this tool does not compute lateral or total surface area, does not convert units, and does not expand edge lengths into base area for a named polygon type. Prefer explicit domain errors over opaque black-box widgets that cannot show why a negative measure is rejected when students paste a sign error from a partially filled form or a transposed dimension list. Each successful request is one billable item at $0.002; failed validation does not consume balance. Accepted inputs must be finite and non-negative; negative base areas and heights are rejected with a clear invalid_input message. Results are fully deterministic: the same base_area and height always yield the same volume. Wire the endpoint into solid-geometry drills, contest answer checkers, CAD preprocessing steps that already know base area and height, or floating worksheets that list only those two measures.
Integration use cases
Deterministic fixtures for solid-geometry tests
Pipelines that seed unit tests or interactive prism demos can call a pure volume oracle instead of reimplementing the product in every language.
Packaging and extrusion from base area and height
Notes that list only base area and extrusion height recover volume as structured JSON for reports, size charts, or lightweight CAD helpers without full meshes.
Technical questions
How do I compute the volume of a right prism with this API?
Send a JSON body with non-negative base_area and height to geom.prism_volume. The response returns volume (base_area×height), the echoed inputs, prism_type right, and the formula V = B · h.
Which formula does the calculator use?
Volume equals base area times height: V = B · h. That is the standard right-prism volume formula when height is the perpendicular distance between the parallel bases.
What happens if base area or height is negative?
The request fails with invalid_input. Negative base_area or height values are rejected and those calls are not charged.