Pressure, volume, and temperature

Ideal Gas Calculator

Use PV = nRT to find one unknown from three known values. Choose your units to calculate absolute pressure, gas volume, amount in moles, or temperature.

Calculate an ideal gas state

Use positive absolute pressure, volume, and amount of gas. Temperature must be above absolute zero. Grouped numbers such as 1,000.50 are accepted.

Use absolute pressure. If you have a gauge reading, add the local atmospheric pressure first. The calculator does not add it automatically.

Enter the actual gas temperature. Celsius and Fahrenheit are converted to kelvin, including the offset. Entering 0°C is valid; 0 K is not.

Changing an input unit keeps the entered number and clears the previous result. Check the value, then calculate again. Changing the result unit converts an existing result without changing your inputs.

Example: 1 mol at 0°C and 101.325 kPa → approximately 22.41397 L.

Volume

Enter your values to see the result.

Calculated in your browser. Press Enter to calculate. Successful results appear in this tab's Recent calculations.

Three worked examples

Volume

One mole at 0°C and 1 atm

V = nRT ÷ P

With T = 273.15 K and P = 101,325 Pa, the volume is approximately 22.41397 L. The stated pressure matters: 1 bar gives a different volume.

Pressure

One mole in 10 L at 25°C

P = nRT ÷ V

Use T = 298.15 K and V = 0.01 m³ to get approximately 247.895703 kPa absolute pressure.

Amount

10 L at 1 bar and 25°C

n = PV ÷ (RT)

With P = 100,000 Pa, V = 0.01 m³, and T = 298.15 K, the amount is approximately 0.403395 mol.

Formula, units, and limits

The ideal gas law is PV = nRT. P is absolute pressure, V is volume, n is amount of substance, and T is thermodynamic temperature in kelvin. Temperature can be found with T = PV/(nR). See OpenStax — The Ideal Gas Law.

We use R = 8.31446261815324 J/(mol·K), the exact product of the SI Avogadro and Boltzmann constants. See the NIST CODATA 2022 constants, Table XXXIII. A fixed, exact constant does not make the ideal gas model or your measurements exact.

One liter is 0.001 m³, one milliliter is 0.000001 m³, one millimole is 0.001 mol, and one kilomole is 1,000 mol. One bar is 100,000 Pa and one standard atmosphere is exactly 101,325 Pa. Temperature conversion uses K = °C + 273.15 and K = (°F + 459.67) × 5/9.

Each known pressure, volume, and amount must be positive; temperature must be above 0 K (−273.15°C or −459.67°F). Negative Celsius or Fahrenheit temperatures above those limits are valid. Zero-valued gas states and vacuum are outside this tool's scope. Hidden fields are ignored.

Inputs accept up to 64 characters, 15 integer digits, and 10 decimal places. Expressions and scientific notation are not accepted. Exact integer fractions retain all arithmetic and unit conversions. Displays round halfway away from zero with trailing zeros omitted; ≈ marks rounding. Changing the result unit or precision uses the unrounded result without adding a history entry.

This is a single-state ideal gas estimate. It does not model reactions, condensation, vapor pressure, compressibility factors, or gas flow. It does not determine a vessel's pressure rating or operating limits.

Common questions

Can I use a gauge pressure reading?

First add the local atmospheric pressure to the gauge pressure. For example, 200 kPa gauge with 101.325 kPa atmospheric pressure is 301.325 kPa absolute. Local atmospheric pressure varies.

Does one mole always occupy 22.4 liters?

No. Gas volume depends on temperature and pressure. Our example explicitly uses 0°C and 1 atm. Different conventions for standard conditions can give different molar volumes.

Why can the temperature result be negative?

Celsius and Fahrenheit temperatures can be negative while the kelvin temperature is positive. The calculation always uses kelvin internally.

Do all real gases follow PV = nRT exactly?

No. Molecular size and interactions can matter. The ideal model is often useful at lower pressures and temperatures well above condensation, but this tool does not estimate its error for a particular gas.