Formula and method
Density ρ = mass/volume. One g/cm³ equals 1,000 kg/m³.
Rearranged, mass = density × volume and volume = mass ÷ density. For example, 0.002 m³ of water at about 1,000 kg/m³ has a mass of 2 kg.
Worked example
A mass of 1 kg occupying 0.001 m³ has density 1,000 kg/m³, or 1 g/cm³.
Units and conversions
Pick the mass unit (g, kg or lb), the volume unit (cm³, m³, L or ft³) and the density unit. The first step divides your numbers as entered, for example ρ = 5 g ÷ 2 cm³ = 2.5 g/cm³, and a second step converts to the density unit you chose, here 2,500 kg/m³.
The conversions use exact factors: 1 lb = 0.45359237 kg and 1 ft = 0.3048 m, so 1 lb/ft³ ≈ 16.018 kg/m³.