Home › Calculators › Ideal Gas Law Calculator

Ideal Gas Law Calculator

Pick the unknown – pressure, volume, moles or temperature – enter the other three in any units, and get the answer with the working and common unit conversions.

Last updated:

Result–
Molar volume V/n–
Number of molecules–

R = 8.314462618 J/(mol·K) = 0.082057366 L·atm/(mol·K). Real gases deviate from ideal behavior at high pressure and low temperature.

Advertisement
Advertisement

How to use the Ideal Gas Law Calculator

  1. Choose what to solve for: P, V, n or T. That field turns green and shows the result.
  2. Enter the other three values and pick their units.
  3. Optionally pick a gas to see the mass and density of the sample.
  4. Press Calculate to see the result, conversions to other units and the working.
  5. Use STP preset to load 1 mol at 0 °C and 1 atm, then change values from there.

The ideal gas law PV = nRT

The ideal gas law links the pressure P, volume V, amount n (in moles) and absolute temperature T of a gas through the gas constant R = 8.314462618 J/(mol·K). Rearranged for each unknown:

  • P = nRT ÷ V
  • V = nRT ÷ P
  • n = PV ÷ RT
  • T = PV ÷ nR

Always use an absolute temperature (kelvin or rankine). The calculator converts °C and °F automatically: K = °C + 273.15.

Worked example

What pressure do 2 mol of gas exert in a 10 L container at 25 °C? Convert to SI: V = 0.010 m³, T = 298.15 K. Then P = 2 × 8.314462618 × 298.15 ÷ 0.010 = 495,794 Pa ≈ 495.8 kPa ≈ 4.89 atm.

At 0 °C and 1 atm, one mole of an ideal gas occupies 8.314462618 × 273.15 ÷ 101,325 = 0.022414 m³ = 22.414 L, the classic molar volume.

Values of R in common units

Value of RUnits
8.314462618J/(mol·K) = Pa·m³/(mol·K)
0.082057366L·atm/(mol·K)
8.314462618L·kPa/(mol·K)
62.363598L·mmHg/(mol·K)
0.08314462618L·bar/(mol·K)
10.731577ft³·psi/(lb-mol·°R)
1.98720cal/(mol·K)

Standard conditions

ConventionTemperaturePressureMolar volume
STP (older, 1 atm)0 °C (273.15 K)101.325 kPa22.414 L/mol
STP (IUPAC since 1982)0 °C (273.15 K)100 kPa (1 bar)22.711 L/mol
SATP25 °C (298.15 K)100 kPa24.790 L/mol
NTP20 °C (293.15 K)101.325 kPa24.055 L/mol

Real gases follow the ideal gas law closely at low pressure and high temperature. Near condensation or at very high pressure, equations such as van der Waals are more accurate.

Frequently asked questions

What is the ideal gas law?

PV = nRT: pressure times volume equals the number of moles times the gas constant times the absolute temperature. It describes how an ideal gas behaves and is a good approximation for most gases at everyday conditions.

What value of R should I use?

Use the value that matches your units: 8.314 J/(mol·K) with pascals and cubic meters, or 0.08206 L·atm/(mol·K) with liters and atmospheres. This calculator converts everything to SI units, so you can mix any units.

Why must temperature be in kelvin?

The gas law is proportional to absolute temperature, which starts at absolute zero. Using °C or °F directly would give wrong or even negative results. The calculator converts automatically: K = °C + 273.15.

What is the volume of one mole of gas at STP?

22.414 L at 0 °C and 1 atm, or 22.711 L at the IUPAC standard of 0 °C and 1 bar. At 25 °C and 1 atm it is about 24.47 L.

How do I find the density of a gas?

Density = PM ÷ RT, where M is the molar mass. Choose a gas in the list and the calculator shows the density in g/L. Dry air at 0 °C and 1 atm is about 1.29 g/L.

When does the ideal gas law fail?

At high pressures and low temperatures, when molecules are close together and attract each other, for example near the boiling point. Then real-gas equations such as van der Waals give better results.

Are all the tools on FreeToolCabin tested for quality and accuracy?

Yes! Every tool on our site undergoes automated Q/A testing in real browser environments to ensure high precision, correct output, and zero errors. If you happen to spot a bug or have a suggestion, please contact us at [email protected] and our team will review it right away.

Related tools

Molar Mass CalculatorMolar mass of any chemical formula with an element-by-element mass % breakdown.Interactive Periodic TableAll 118 elements with colour modes, filters, search and full element details.Chemical Equation BalancerBalance chemical, ionic and redox equations with the matrix method and steps.Scientific CalculatorTrig, logs, powers and more in your browser.ATM to PSIConvert atmospheres to pounds per square inch (atm to psi) instantly, with formula and chart.Bar to PSIConvert bar to pounds per square inch (bar to psi) instantly, with formula and chart.Kinetic Energy CalculatorSolve KE = ½mv² and PE = mgh for energy, mass, speed or height, with unit conversions.kPa to BarConvert kilopascals to bar (kPa to bar) instantly, with formula and chart.BMI CalculatorCalculate BMI and a healthy weight range.Sleep CalculatorFind the best bedtime or wake-up time using 90-minute sleep cycles.Body Fat CalculatorBody fat % with the US Navy and BMI methods, lean vs fat mass.Ideal Weight CalculatorCompare ideal body weight from the Robinson, Miller, Devine and Hamwi formulas.Weight Loss Percentage CalculatorWork out the percentage of body weight you have lost and track progress to your goal.Waist to Hip Ratio CalculatorWork out your waist-to-hip ratio and WHO health risk category for men and women.Lean Body Mass CalculatorEstimate lean body mass, fat mass and body fat % with the Boer, James and Hume formulas.Pregnancy Weight Gain CalculatorSee your recommended pregnancy weight gain by BMI and week, using the IOM 2009 guidelines.Baby Percentile CalculatorWeight, length and head circumference percentiles for babies 0–24 months on WHO growth charts.Life Expectancy CalculatorEstimate remaining life expectancy from age and sex, with rough lifestyle adjustments.Blood Alcohol CalculatorEstimate BAC over time from your drinks with the Widmark formula, with peak and time to sober.A1C CalculatorConvert A1C % to estimated average glucose in mg/dL and mmol/L, and back.FFMI CalculatorFind your fat-free mass index and normalized FFMI from weight, height and body fat.Puppy Weight CalculatorEstimate your puppy's adult weight from its age, current weight and breed size.Growth Rate CalculatorTotal growth, compound growth rate per period, linear average and a projection.Army Body Fat CalculatorArmy tape test body fat (2023 one-site or legacy method) vs AR 600-9 standards by age.Blood Pressure CalculatorBlood pressure reading to AHA category, mean arterial pressure and pulse pressure.Waist to Height Ratio CalculatorWaist to height ratio in cm or inches with health bands and the 0.5 rule waist target.Alcohol Units CalculatorUK alcohol units from volume and ABV, plus a weekly total vs the 14-unit guideline.Barbell Plate CalculatorWhich plates to load on each side of the bar for any target weight, in kg or lb.GFR CalculatorEstimate eGFR from creatinine, age and sex with CKD-EPI 2021 and see the CKD stage.Mean Arterial Pressure CalculatorCalculate mean arterial pressure (MAP) and pulse pressure from a blood pressure reading.Body Shape CalculatorFind your body shape (hourglass, pear, apple, rectangle) from bust, waist and hip sizes.Child BMI CalculatorBMI and CDC BMI-for-age percentile for kids and teens 2–20, with weight category.Horse Weight CalculatorEstimate a horse's weight in kg and lb from heart girth and body length tape measurements.Quit Smoking Savings CalculatorMoney saved, cigarettes not smoked and health milestones since your quit date.Sun Position CalculatorSolar altitude, azimuth and shadow length for any place and time, with a daily sun chart.Tire Age CalculatorDecode the DOT tire date code to see when a tire was made, its age and when to replace it.Tree Age CalculatorEstimate how old a tree is from its trunk circumference and species growth factor.Yarn Yardage CalculatorEstimate yards or metres of yarn and skeins needed by project, size and yarn weight.Child Height Percentile CalculatorFind a child's height-for-age percentile and z-score on the CDC growth chart, ages 2 to 20.Cycling Power CalculatorWatts needed for a speed, or speed from watts, using weight, gradient, CdA, Crr and wind.Diabetes Risk TestQuick type 2 diabetes risk score from age, family history, blood pressure, activity and weight.Ergonomic Desk Height CalculatorIdeal sitting and standing desk, chair, keyboard and monitor height from your height.Eyeglass Prescription ExplainedTurn SPH, CYL, AXIS, ADD and PD into a plain-English explanation of your glasses prescription.Heart Disease Risk CalculatorFramingham 10-year heart disease risk and heart age from cholesterol, BP, smoking and diabetes.Meat Temperature GuideUSDA safe internal temperature, doneness, pull temp, carryover and rest time for any meat.Metabolic Age CalculatorEstimate your metabolic age by comparing your BMR with healthy-weight averages for each age.Passer Rating CalculatorCalculate NFL quarterback passer rating and NCAA passing efficiency from a stat line.Relative Fat Mass CalculatorEstimate body fat % from height, waist and sex with the RFM formula, and compare it with BMI.Running Route Distance CalculatorClick on a map to draw a running, walking or cycling route and get distance, laps and finish time.Skinfold Body Fat CalculatorBody fat % from caliper readings: Jackson-Pollock 3, 4, 7-site and Durnin-Womersley.Strength Standards CalculatorYour lift level (beginner to elite) and bodyweight ratio from lift, body weight, sex and age.Sugar Intake CalculatorYour daily added sugar limit in grams and teaspoons (AHA and WHO), compared with your intake.Swimming Laps CalculatorHow many laps or lengths make a mile or km in a 25 yd, 25 m or 50 m pool, and laps to miles.Weight TrackerLog weigh-ins and see a 7-day average chart, weekly trend and projected goal date.Win Percentage CalculatorTurn a win-loss-tie record into a win percentage and see the wins needed to hit a goal.Biological Age CalculatorEstimate your biological age from sleep, exercise, smoking, diet, BMI and blood pressure.Body Roundness Index CalculatorBRI from waist and height, with risk band chart, estimated body fat and visceral fat signal.Car Seat Stage FinderEnter age, weight and height to see which car seat stage your child needs, per AAP guidance.
See all 51 Health & Body Calculators →