Skip to content
100% local

Density, mass and volume calculator

Enter any two of density, mass and volume and get the third, with the formula used.

Input

Density, mass and volume calculator

Density, mass and volume are linked by one equation — ρ = m / V — so knowing any two always gives you the third. This calculator does that math for you: choose which two quantities you have, paste one or more items as label;value;value, and it computes the missing one along with the formula it used. It's built for physics and chemistry homework, materials estimating, shipping and packaging calculations, and any recipe or DIY project where you know a weight and need a volume, or the other way around.

Three option groups control the math. "Known quantities" picks which two values each line supplies — mass and volume, density and mass, or density and volume — and the calculator works out the third. "Material density" fills in a standard value for water, steel, aluminum, concrete or wood, so a line only needs one number instead of a density you'd otherwise have to look up. Density, mass and volume units are independently selectable (kg/m³, g/cm³ or lb/ft³ for density; kg, g or lb for mass; m³, cm³ or L for volume), and results convert automatically. Turn on relative density to also see the value as a ratio against water — the same thing as specific gravity.

Paste several items, one per line, and every line is calculated independently; a line with a label keeps it in the output, and a badly formatted or non-numeric line is skipped and listed separately rather than stopping the whole calculation. Decimal places are adjustable up to six, and results can be shown as a labelled text line per item or as an aligned table — handy for a quick copy into a spreadsheet.

Everything runs locally in your browser: nothing you paste in is uploaded or stored anywhere. Copy the result, download it as a .txt file, or send the output straight back into the input to refine a calculation without retyping it.

FAQ

What formula does it use?
Density equals mass divided by volume (ρ = m / V). The calculator rearranges this to solve for whichever quantity is missing and shows the formula it applied.
How does the material option work?
Pick a material like steel or water and its standard density is used automatically, so a line only needs to supply mass or volume — not both a density and a value.
What is relative density?
Also called specific gravity, it's a material's density divided by the density of water (1000 kg/m³). A value above 1 sinks in water; below 1 floats.
What happens if a line is invalid?
It's skipped and listed under the result with the line number, so the rest of your list still calculates.
Is my data uploaded anywhere?
No. Every calculation runs entirely in your browser — nothing you type or paste ever leaves your device.