Home › Weather & Environment › Air Density Calculator
Air Density Calculator
Computes the density of humid air from temperature, station pressure and relative humidity as a mixture of ideal gases (dry air plus water vapour, vapour pressure from the Magnus formula), and the ISA density altitude.
When to use
You need air density for aerodynamics, engine or fan performance, ballistics or HVAC, or the density altitude for aircraft performance planning.
Do not use when: You only have sea-level (QNH) pressure and no elevation (convert to station pressure with pressure-altitude first), or you need gas density for a gas other than air (use ideal-gas-law).
Formula
pv = RH/100 · 6.1094·exp(17.625·T/(243.04 + T)) hPa; ρ = (p − pv)·100/(287.058·T_K) + pv·100/(461.495·T_K); density altitude = 44330.8 × [1 − (ρ/1.225)^0.23497] m
Ideal-gas mixture with Rd = 287.058 and Rv = 461.495 J/(kg·K); the compressibility factor (≈ 0.9996 at sea level) is ignored. Density altitude inverts the ISA troposphere density profile (exponent 1/(g·M/(R·L) − 1)).
Inputs
| Parameter | Type | Unit | Required | Description |
|---|---|---|---|---|
temperature | number | yes | Air temperature in temperature_unit. Range: ≥ -80, ≤ 140 | |
temperature_unit | enum: c | f | default c | Unit of the temperature input(s). | |
pressure | number | yes | Actual barometric pressure at the location, in pressure_unit (not the sea-level-corrected QNH/altimeter setting). Range: > 0, ≤ 1200 | |
pressure_unit | enum: hpa | kpa | inhg | mmhg | default hpa | Unit of the pressure input. | |
relative_humidity_percent | number | % | default 0 | Relative humidity in percent; 0 gives dry air. Range: ≥ 0, ≤ 100 |
Outputs
| Output | Type | Unit | Description |
|---|---|---|---|
air_density_kg_m3 | number | kg/m³ | Density of the moist air. |
air_density_lb_ft3 | number | lb/ft³ | Same density in pounds per cubic foot. |
dry_air_density_kg_m3 | number | kg/m³ | Density at the same temperature and pressure with 0 % humidity, for comparison. |
vapor_pressure_hpa | number | hPa | Partial pressure of water vapour. |
percent_of_isa_sea_level | number | % | Density as a percentage of 1.225 kg/m³ (ISA, 15 °C, 1013.25 hPa, dry). |
density_altitude_m | number | m | Altitude in the ISA at which dry air would have this density. |
density_altitude_ft | number | ft | Density altitude in feet. |
Example
ISA sea level: 15 °C, 1013.25 hPa, dry: {"temperature":15,"temperature_unit":"c","pressure":1013.25,"pressure_unit":"hpa","relative_humidity_percent":0} → {"air_density_kg_m3":1.225,"dry_air_density_kg_m3":1.225,"percent_of_isa_sea_level":100,"density_altitude_m":0,"density_altitude_ft":0}
30 °C, 1000 hPa, 50 % RH: {"temperature":30,"temperature_unit":"c","pressure":1000,"pressure_unit":"hpa","relative_humidity_percent":50} → {"air_density_kg_m3":1.1399,"dry_air_density_kg_m3":1.1491,"vapor_pressure_hpa":21.18,"air_density_lb_ft3":0.07116,"density_altitude_m":743,"density_altitude_ft":2439}
GET https://tttkmbb.com/api/v1/calculate/air-density?temperature=15&temperature_unit=c&pressure=1013.25&pressure_unit=hpa&relative_humidity_percent=0
Machine access
- API:
GET https://tttkmbb.com/api/v1/calculate/air-density(query parameters) orPOSTwith a JSON body{"inputs": {...}} - Schema: https://tttkmbb.com/api/v1/calculators/air-density · Markdown: https://tttkmbb.com/weather/air-density.md · JSON definition: https://tttkmbb.com/weather/air-density.json
- MCP: server
https://tttkmbb.com/mcp, toolrun_calculator with calculator_id="air-density" - OpenAPI operationId:
calculate_air_density - Freshness:
static. Authentication: none. Rate limit: fair use (see rate limits).
Sources
FAQ
Why is humid air lighter than dry air?
Water vapour (molar mass 18 g/mol) displaces nitrogen and oxygen (29 g/mol average) at the same pressure, so the mixture has lower density; at 30 °C the effect is about 1 %.
Which pressure should I enter?
The station (absolute) pressure. Weather reports usually give sea-level-reduced pressure; use pressure-altitude with your elevation to derive the station pressure first.
How does density altitude affect aircraft?
Higher density altitude means less lift, less engine power and less propeller thrust: takeoff distances grow and climb rates fall; pilots use it in performance charts.
Related calculators
- Pressure Altitude Calculator — Convert QNH and elevation to station pressure and pressure altitude.
- Ideal Gas Law Calculator — General PV = nRT calculations.
- Dew Point Calculator — Humidity measures used in the vapour-pressure term.