Density Calculator
Calculate density, mass or volume from the other two, with a reference table of common materials and a float-or-sink check.
How to use this calculator
- 1Choose which quantity you want.
- 2Enter the other two — mass in grams, volume in cubic centimetres, density in kg/m³.
- 3The material table shows what your result is closest to.
How the calculation works
ρ = m / V m = ρV V = m / ρ- ρ (rho)
- Density — mass per unit volume
- m
- Mass
- V
- Volume
Grams per cubic centimetre and kilograms per cubic metre differ by exactly a factor of 1000, which is why water is both 1 g/cm³ and 1000 kg/m³.
Specific gravity is density relative to water, so it is dimensionless — a specific gravity of 2.7 means 2.7 times as dense as water.
An object floats when its average density is below that of the fluid. A steel hull floats because the enclosed air lowers its average density below water’s.
Worked example
500 g occupying 250 cm³
- 1.ρ = 500 g ÷ 250 cm³ = 2 g/cm³.
- 2.Converting: 2 g/cm³ × 1000 = 2000 kg/m³.
- 3.Specific gravity is 2.0, so it is twice as dense as water and will sink.
Result: 2000 kg/m³ (2 g/cm³)
What density describes
Density is a material’s mass packed into a given volume — how much "stuff" is crammed into a given amount of space. Two objects made of the same material always have the same density regardless of their size or shape: a small block of aluminium and a large aluminium beam have identical density, even though their masses and volumes are very different, because density is a ratio between the two rather than either quantity alone.
This is what makes density useful for identifying an unknown material or checking whether something is genuine — a gold bar and a lead brick sized to weigh the same occupy very different volumes, because gold is nearly twice as dense as lead. Density comparisons like this remain a standard first check in fields from metallurgy to geology to quality control.
Archimedes and the origin of density measurement
The best-known origin story for measuring density by displacement involves Archimedes of Syracuse in the third century BC. According to the traditional account, King Hiero II suspected a goldsmith had replaced some of the gold in a commissioned crown with a cheaper, less dense metal while keeping the total weight the same. Archimedes is said to have realised, while lowering himself into a bath and watching the water level rise, that he could measure an irregular object’s volume by how much fluid it displaced — and from there, calculate its density and compare it against pure gold.
Whether or not the "Eureka" detail of the story is literally true, the underlying principle it illustrates is real and remains foundational: an object submerged in a fluid displaces a volume of that fluid exactly equal to its own volume, which is what makes density measurable indirectly through displacement rather than requiring a regularly shaped object that can be measured with a ruler.
Density and buoyancy
Whether an object floats or sinks in a given fluid comes down entirely to a comparison of densities: an object less dense than the fluid floats, and one denser than the fluid sinks, regardless of its total size or weight. This is also the buoyancy principle behind Archimedes’ crown problem — the buoyant force pushing an object upward equals the weight of the fluid it displaces.
It is also why a solid block of steel sinks while a steel ship floats: the ship’s hull encloses a large volume of air, which lowers the vessel’s average density — hull, engines, cargo and all the enclosed air together — below the density of water, even though the steel itself is nearly eight times denser than water on its own.
Specific gravity, a unitless shortcut
Specific gravity expresses a material’s density as a simple ratio to water’s density, which makes it unitless — a specific gravity of 2.7 means "2.7 times as dense as water," true whether density is being measured in kilograms per cubic metre or grams per cubic centimetre. This is convenient for quick comparisons, and is the same figure this calculator reports alongside density in more conventional units.
Specific gravity has long been measured directly with a hydrometer — a weighted, sealed float that sits at different depths in different liquids depending on their density — a tool still used today for jobs like checking a car battery’s charge state or the sugar content of fermenting wine and beer, both of which shift the liquid’s density in predictable ways.
What this assumes, and where it stops
Assumptions
- A uniform material at around 20 °C and atmospheric pressure.
Limitations
- Density changes with temperature — water is densest at 4 °C, which is why ice floats.
- Gas densities vary strongly with pressure and temperature; the air figure here is for sea level at 15 °C.
- Porous and composite materials have a bulk density that differs from their material density.
Common questions
What is the difference between density and specific gravity?
Density has units — kilograms per cubic metre, or grams per cubic centimetre. Specific gravity is density divided by the density of water, so it has no units at all. A material with a density of 2700 kg/m³ has a specific gravity of 2.7, meaning it is 2.7 times as dense as water.
Why does ice float on water?
Because water is unusual: it is densest at 4 °C, and expands as it freezes. Ice has a density of about 917 kg/m³ against water’s 1000, so roughly 92% of an iceberg sits below the surface and 8% above. Almost every other substance is denser as a solid than as a liquid.
Formula and content last reviewed on .
Results are estimates for information only, not professional advice.
Related calculators
Tools people commonly use alongside the density calculator.