Gas Density Calculator screenshot

Gas Density Calculator

Compute gas density with rho = PM/RT using pressure in kPa, molar mass in g/mol and temperature in kelvin.

Privacy First
0 Runs
Updated 2026-11-06
No upload
Instant
No signup

Gas density from the ideal gas law

The page evaluates density as pressure times molar mass divided by R times temperature, with pressure in kPa, molar mass in g/mol, R = 8.314 LkPa/(molK) and temperature in kelvin. Carbon dioxide at 101.325 kPa and 273.15 K comes out at 1.96 grams per litre.

Pressure and molar mass must be above zero. A temperature of 0 K or below is refused, because the formula divides by T and absolute zero is not a state a gas occupies. The page treats the gas as ideal, so a real gas near its condensation point will be denser than this figure.

Everything is computed from the four numbers you type. The same inputs print the same density after a reload, and no value leaves the browser.

The page evaluates ρ = PM/RT with pressure in kPa, molar mass in g/mol, R = 8.314 L·kPa/(mol·K) and temperature in kelvin, and prints the density in grams per litre. Carbon dioxide at 101.325 kPa and 273.15 K comes out at 1.96 g/L.

The gas is treated as ideal, so a real gas near its condensation point is denser than this figure and a gas at high pressure is denser still; the page does not apply a compressibility factor.

How to use it

Enter the three values and press Run. Use kPa for pressure, g/mol for molar mass and kelvin for temperature — the constant 8.314 L·kPa/(mol·K) is the one written into the page, so pressure in atm or temperature in °C gives an answer with no meaning.

  • Enter pressure in kPa.
  • Enter molar mass in g/mol, not kg/mol.
  • Enter temperature in K and read the density in g/L.

The arithmetic, and where it stops

Density is the molar mass scaled by how many moles occupy a litre, and PV = nRT says that is P/RT. The whole calculation is one multiplication and one division by 8.314 × T: at 273.15 K the divisor is 2271, so 101.325 × 44.01 / 2271 = 1.96 g/L.

Pressure and molar mass must be above zero, and a temperature of 0 K or below is refused, because the formula divides by T and absolute zero is not a state a gas occupies.

What to Expect

Best for

  • Getting an order-of-magnitude gas density for a vessel or a duct.

What this tool keeps

  • The division runs in this tab with the constant written into the page; nothing is uploaded. The same figures give the same result after a reload.

Sample input

101.325, 44.01, 273.15

Sample output

ρ = 1.96 g/L

Frequently asked questions

How do I use the Gas Density Calculator?

Enter the three values and press Run. Use kPa for pressure, g/mol for molar mass and kelvin for temperature — the constant 8.314 L·kPa/(mol·K) is the one written into the page, so pressure in atm or temperature in °C gives an answer with no meaning.

Does anything leave my browser?

No. The division runs in this tab with the constant written into the page; nothing is uploaded. Reloading the page discards every value you entered.

Which inputs does it refuse?

Pressure and molar mass must be above zero, and a temperature of 0 K or below is refused, because the formula divides by T and absolute zero is not a state a gas occupies.

Developer program

Build custom tools for your store

Join the SDK program to create useful ecommerce utilities for your store.