Ideal Gas Law Calculator
Solve the ideal gas law, PV = nRT, for pressure, volume, moles or temperature with unit conversion, the working shown and molar volume alongside.
Calculator
Converted to kelvin internally. Gas laws are invalid on °C.
Working, with your numbers
- P = nRT / V
- = (1 x 8.31446 x 273.15) / 0.0224
- = 101,390 Pa
Values are converted into the units the equation is worked in before the arithmetic.
- Molar volume 22.414 L/mol at 0 °C and 1 atm; 24.465 L/mol at 25 °C and 1 atm; 24.790 L/mol at 25 °C and 1 bar.
- 22.4 L/mol
- Concentration
- 44.64 mmol/L
- Molecules
- 6.022 × 10²³
Citing this tool
Last updated . Add the date you accessed it as well, which a citation of a page that can change asks for. If a specific result matters, cite the permalink from the tool’s share row instead of this page: it reproduces the exact parameters.
The equation
Clapeyron (1834), combining the Boyle, Charles and Avogadro laws
What PV = nRT is saying
The ideal gas law, PV = nRT, says the pressure
P of a gas times its volume V equals the amount
of gas n in moles times the gas constant R times
the temperature T in kelvin. It bundles three older
observations into one statement. Boyle found that pressure and volume are
inversely proportional at fixed temperature, Charles found that volume
rises in proportion to absolute temperature, and Avogadro found that equal
volumes of gas at the same conditions hold equal numbers of particles. Put
together,
PV = nRT says the product of pressure and volume is fixed by
how much gas you have and how hot it is.
The gas constant R = 8.31446261815324 J/(mol·K) is exact under the 2019 SI, being the product of the Avogadro and Boltzmann constants, and 8.314463 to seven figures. You may also meet it as 0.082057 L·atm/(mol·K), which is the same constant in units that suit litres and atmospheres. This calculator converts everything to pascals, cubic metres and kelvin internally, so you can mix atmospheres with millilitres safely.
Worked example
How many moles of gas fill a 2.5 L vessel at 3.0 atm and 25 °C?
- Convert: 3.0 atm is 303,975 Pa, 2.5 L is 0.0025 m³, 25 °C is 298.15 K.
n = PV / RT = (303975 × 0.0025) / (8.314463 × 298.15)n = 759.94 / 2478.96 = 0.3066 mol
Switch the solve-for selector to "Amount of gas", enter those three values in whatever units you like, and you get the same figure without doing any conversions by hand.
Molar volume, and why the conditions matter
One mole of an ideal gas occupies 22.414 L at 0 °C and 1 atm. That is the number most people memorise, but it is only true for those exact conditions. At 25 °C and 1 atm it is 24.465 L/mol, and against the IUPAC standard pressure of 1 bar the figures become 22.711 and 24.790 L/mol respectively.
"Standard conditions" has meant different things at different times, which is why a molar volume quoted without its temperature and pressure is not usable. The calculator reports molar volume alongside your answer so you can see which case you are actually in.
Common mistakes
- Using Celsius. The law is proportional in absolute temperature. At 0 °C a Celsius substitution predicts zero pressure, which is plainly wrong. Always kelvin.
- Mismatched volume and pressure units. Pascals demand cubic metres. Pairing pascals with litres is out by a factor of a thousand.
- Treating ΔT like T. A gas heated by 10 K has not had its pressure raised by a factor of ten. Only ratios of absolute temperatures matter.
- Applying it near condensation. Close to the boiling point, or at very high pressure, molecular volume and attraction stop being negligible and the law drifts. Below a few atmospheres and well above the boiling point the error is usually under one percent.
Converting units first? Use the volume, amount of substance, pressure and temperature conversion tables.
Worked examples
Each one runs through the calculator above, so the arithmetic here is the arithmetic it does.
What volume does 1 mole of any gas occupy at STP (0 °C and 1 atm)?
- V = nRT / P
- = (1 x 8.31446 x 273.15) / 101,325
- = 0.022414 m3 = 22.414 L
The 22.4 litres worth committing to memory, and note what it does not depend on: not the gas, not the molar mass, nothing but pressure and temperature. At 25 °C rather than 0 °C it is 24.5 L, which is why a question specifying room temperature wants a different number. Since 1982 IUPAC has defined STP as 0 °C and 1 bar, which gives 22.711 L, so check which definition your course uses.
What pressure does 2 moles of gas exert in a 10 litre container at 25 degrees?
- P = nRT / V
- = (2 x 8.31446 x 298.15) / 0.01
- = 495,790 Pa
The temperature has to become 298.15 K before it enters the equation. Using 25 directly gives a pressure about twelve times too low, and it is the error the calculator’s unit selector exists to prevent.
How many moles of gas are in a 2 litre bottle at 3 atmospheres and 20 degrees?
- n = PV / RT
- = (303,975 x 0.002) / (8.31446 x 293.15)
- = 0.24943 mol
Solving for the amount of gas rather than a state variable, which is what the ideal gas law can do and the combined gas law cannot: the combined law cancels n and R, so it never asks how much gas is present.
Practise this with Thermodynamics Practice Problems, questions generated from this calculator and 8 other calculators in Thermodynamics.
Common questions
Why must temperature be in kelvin?
Because the law is proportional in absolute temperature. Doubling from 10 °C to 20 °C does not double the pressure, but doubling from 283 K to 566 K does. Using Celsius makes the arithmetic meaningless and breaks entirely at 0 °C, where it would predict zero pressure. This tool converts for you.
What is the molar volume of a gas?
It is 22.414 L/mol at 0 °C and 1 atm, and 24.465 L/mol at 25 °C and 1 atm. Against the IUPAC standard pressure of 1 bar the figures are 22.711 and 24.790 L/mol. Quoting a molar volume without stating the conditions is the most common source of confusion here.
When does the ideal gas law stop working?
At high pressure and low temperature, where molecular volume and intermolecular attraction stop being negligible. Below a few atmospheres and well above the boiling point the error is usually under one percent. Near condensation, use a real-gas equation such as van der Waals instead.