Relative Humidity Calculator
Updated June 14, 20267 min read

How to Calculate Relative Humidity from Vapor Pressure, Water Vapor, Mixing Ratio, and Specific Humidity

If you know actual vapor pressure, water vapor content, mixing ratio, or specific humidity — here is how to calculate relative humidity from each. Exact formulas, step-by-step examples, and a reference table.

Your weather station outputs actual vapor pressure in hPa. Your HVAC datalogger records mixing ratio in g/kg. Your atmospheric model gives specific humidity. But the display on your thermostat — and the threshold your mold inspector uses — is relative humidity as a percentage.

Converting between these measures requires exactly one thing: temperature. Here are the exact formulas for every starting point, with worked examples and a reference table. For instant conversion without the manual math:


The Master Formula: Relative Humidity from Vapor Pressure

Relative humidity is simply the ratio of actual vapor pressure to saturation vapor pressure at the same temperature, expressed as a percentage.

RH = (e / e_s(T)) × 100 [%]

Where: e = actual vapor pressure (hPa or mbar) e_s(T) = saturation vapor pressure at temperature T

Saturation vapor pressure (Magnus-Tetens formula): e_s(T) = 6.112 × exp(17.625 × T / (243.04 + T)) [hPa]

T = air temperature in °C

This formula is the foundation. Everything else below derives from it.


Method 1: How to Calculate Relative Humidity from Actual Vapor Pressure

If you have actual vapor pressure from a weather station, radiosonde, or psychrometric calculation, this is the most direct route.

Step-by-step:

  1. Look up or measure air temperature T (°C)
  2. Calculate saturation vapor pressure: e_s = 6.112 × exp(17.625T / (243.04 + T))
  3. Divide actual vapor pressure by saturation: RH = (e / e_s) × 100

Worked example:

Given: actual vapor pressure e = 18.5 hPa, air temperature T = 28°C

e_s(28) = 6.112 × exp(17.625 × 28 / 271.04)
        = 6.112 × exp(1.821)
        ≈ 6.112 × 6.178
        ≈ 37.76 hPa

RH = (18.5 / 37.76) × 100 ≈ 49.0%

At 28°C with an actual vapor pressure of 18.5 hPa: RH ≈ 49%

How to Calculate Vapor Pressure from Relative Humidity (Reverse)

Going the other way — finding vapor pressure from temperature and RH:

e = e_s(T) × (RH / 100) [hPa]

At 25°C and 65% RH: e_s(25) ≈ 31.67 hPa, so e = 31.67 × 0.65 ≈ 20.59 hPa


Method 2: How to Calculate Relative Humidity from Water Vapor Content (Absolute Humidity)

If you know absolute humidity in g/m³ (grams of water vapor per cubic meter of air):

Step 1 — Saturation absolute humidity: AH_sat(T) = 216.7 × e_s(T) / (T + 273.15) [g/m³]

Step 2 — Relative humidity: RH = (AH / AH_sat(T)) × 100 [%]

Example: Water vapor content = 14.0 g/m³, temperature = 25°C

e_s(25) ≈ 31.67 hPa
AH_sat(25) = 216.7 × 31.67 / 298.15 ≈ 23.01 g/m³
RH = (14.0 / 23.01) × 100 ≈ 60.8%

For more on this conversion see our detailed guide on calculating relative humidity from absolute humidity.


Method 3: How to Calculate Relative Humidity with Temperature and Mixing Ratio

Mixing ratio (W) is the mass of water vapor per kg of dry air (g/kg). HVAC engineers and meteorologists often have this value from dataloggers or atmospheric models. To convert back to RH:

Step 1 — Convert mixing ratio to vapor pressure: e = (W × P) / (621.98 + W) [hPa]

Step 2 — Apply master formula: RH = (e / e_s(T)) × 100 [%]

Where: W = mixing ratio [g/kg] P = atmospheric pressure [hPa] (1013.25 at sea level) T = dry-bulb air temperature [°C]

Worked example:

Given: Mixing ratio W = 12.0 g/kg, Temperature T = 25°C, Sea level (P = 1013.25 hPa)

e = (12.0 × 1013.25) / (621.98 + 12.0)
  = 12,159 / 633.98
  ≈ 19.18 hPa

e_s(25) ≈ 31.67 hPa

RH = (19.18 / 31.67) × 100 ≈ 60.6%

At 25°C with a mixing ratio of 12.0 g/kg: RH ≈ 61%


Method 4: How to Calculate Relative Humidity with Temperature and Specific Humidity

Specific humidity (q) uses a slightly different denominator than mixing ratio — it divides by total (moist) air mass. The conversion to RH is nearly identical:

Step 1 — Convert specific humidity to vapor pressure: e = (q × P) / (622 + 0.378 × q) [hPa] ≈ (q × P) / 622 [hPa, valid to less than 1% error at typical humidity levels]

Step 2 — Apply master formula: RH = (e / e_s(T)) × 100 [%]

Where: q = specific humidity [g/kg]

Example: q = 11.8 g/kg, T = 25°C, P = 1013.25 hPa

e ≈ (11.8 × 1013.25) / (622 + 0.378 × 11.8)
  = 11,956 / 626.46
  ≈ 19.08 hPa

RH = (19.08 / 31.67) × 100 ≈ 60.2%

Relative Humidity Reference Table (via Vapor Pressure)

Saturation vapor pressure values and the actual vapor pressure at common RH levels:

Temperaturee_s (100% RH)e at 70% RHe at 50% RHe at 30% RH
5°C8.72 hPa6.10 hPa4.36 hPa2.62 hPa
10°C12.28 hPa8.60 hPa6.14 hPa3.68 hPa
15°C17.06 hPa11.94 hPa8.53 hPa5.12 hPa
20°C23.38 hPa16.37 hPa11.69 hPa7.01 hPa
25°C31.67 hPa22.17 hPa15.84 hPa9.50 hPa
30°C42.43 hPa29.70 hPa21.22 hPa12.73 hPa
35°C56.26 hPa39.38 hPa28.13 hPa16.88 hPa

Values computed using Magnus-Tetens formula with Alduchov & Eskridge (1996) coefficients.


Calculating Relative Humidity from Saturation Vapor Pressure

A related search that comes up often: "calculating relative humidity from saturation vapor pressure."

Saturation vapor pressure (e_s) is a property of the temperature — it tells you the maximum possible vapor pressure at that temperature. It is not a measurement you take; you compute it from temperature using the Magnus formula. So to get RH from saturation vapor pressure:

  • You already know e_s — that is your temperature's saturation limit
  • You need one more value: the actual vapor pressure e (or dew point, or mixing ratio)
  • Then: RH = (e / e_s) × 100

If you only have the saturation vapor pressure without knowing the actual vapor pressure, you cannot calculate RH — you need one additional measurement. See the relative humidity formula explained for a deeper dive into how these quantities relate.


Frequently Asked Questions

What is the difference between vapor pressure and water vapor pressure? They are the same thing. "Water vapor pressure," "vapor pressure," and "partial pressure of water vapor" all refer to the contribution of water vapor to total atmospheric pressure — typically expressed in hPa or mbar. In meteorology and psychrometrics, "vapor pressure" is the standard shorthand.

If I know the dew point, can I calculate vapor pressure without knowing the air temperature? Yes. The dew point is the temperature at which the saturation vapor pressure equals the actual vapor pressure. So actual vapor pressure e = e_s(dew point) = 6.112 × exp(17.625 × Td / (243.04 + Td)), where Td is the dew point in °C. You do not need air temperature to find actual vapor pressure from dew point.

What units does this calculator use for vapor pressure? The calculator outputs "Saturation Vapor Pressure" and "Actual Vapor Pressure" in hPa (hectopascals), which are numerically identical to mbar. To convert to kPa, divide by 10. To convert to mmHg (Torr), multiply by 0.750062.

Can relative humidity exceed 100% if vapor pressure exceeds saturation pressure? Briefly, yes — supersaturation occurs in very clean air that lacks condensation nuclei. This is the principle behind cloud chambers in physics labs. Under normal atmospheric conditions, excess vapor pressure almost immediately condenses into liquid droplets, and RH stays at or below 100%.

How accurate is the Magnus formula for computing saturation vapor pressure? The Magnus-Tetens formula with Alduchov & Eskridge (1996) coefficients (a = 17.625, b = 243.04) is accurate to ±0.35°C equivalent (meaning the dew point derived from it is accurate to ±0.35°C) across the range −40°C to 60°C. This is the same precision used by NOAA and most national weather services. For temperatures below −40°C, the Goff-Gratch formula is preferred.

Ready to run the numbers?

Get your result instantly — private, in your browser.

Open the calculator →