Ideal gas · PV = nRT · Density

Ideal gas law calculator (PV = nRT & gas laws)

Solve PV = nRT, the combined gas law, and gas density and molar mass problems with automatic unit conversions.

All calculations run in your browser; nothing is uploaded.

How to use (3 steps)

  1. Select the mode: ideal gas (PV = nRT), combined gas law, or density & molar mass.
  2. Choose the “Solve for” target, then fill the other fields with their units.
  3. Tap Compute to solve and see the steps. Copy URL shares the exact setup with units.

A standard-state example is preloaded and computed automatically so you can see the outputs at a glance.

Use Ideal for a single state (PV = nRT), Combined gas law for before/after conditions (Boyle’s / Charles’ / combined law in one equation), and Density & molar mass when you need ρ, M, P, T from the relation ρ = PM/(RT).

Inputs

Temperatures in °C are converted to K automatically. Units can be mixed; the calculation runs in SI internally.

Ideal gas (PV = nRT)

mol

Results

How it is calculated

    FAQ

    Can I enter temperature in °C?

    Yes. Choose °C for the temperature unit and the calculator converts it to kelvin internally before solving.

    Which mode should I choose?

    Use Ideal when you want to solve PV = nRT for one variable. Use the combined gas law when comparing two states (it covers Boyle’s and Charles’ laws in one step). Use Density & molar mass to relate ρ, M, P, and T for a single state.

    Which units are used in the calculation?

    All inputs are converted to consistent SI units (Pa, m³, K, mol) before solving. The gas constant R value is matched to the selected unit system automatically.

    Is this valid for real gases?

    This tool assumes an ideal gas. Many gases follow it near room conditions, but at high pressure or low temperature real-gas corrections may be needed.

    Comments

    Click to load the discussion. Comments are powered by Giscus and load only when requested.