An online relative humidity calculator works out the ratio of water vapor actually in the air to the maximum amount the air can hold at that temperature, expressed as a percentage. You enter the air temperature and either the dew point or the wet-bulb temperature (depending on the calculator), and you get back the relative humidity. This page explains the formula behind it, how to use the results correctly, and the common mistakes that lead to wrong readings.
Formula
The calculator uses the Magnus formula, a standard approximation for the saturation vapor pressure of water over liquid water. The relative humidity (RH) is the ratio of actual vapor pressure (e) to saturation vapor pressure (es) at the air temperature, times 100:
RH = 100 × e / es(t)
where the vapor pressure is computed from the dew point (td) and the saturation pressure from the air temperature (t):
e = 6.1094 × exp(17.625 × td / (243.04 + td)) (in hPa)
es = 6.1094 × exp(17.625 × t / (243.04 + t)) (in hPa)
Here, t and td are both in degrees Celsius. The constants 17.625 and 243.04 are empirical coefficients from the Magnus formulation (Alduchov and Eskridge, 1996) that give good accuracy over the range −40 °C to +60 °C. The 6.1094 hPa is the saturation vapor pressure at 0 °C. When you plug the two equations into the ratio, the 6.1094 cancels, which is why the calculator expression only shows the exponential part.
Worked Example
Take the default values: air temperature t = 25 °C, dew point td = 15 °C.
- Compute the saturation vapor pressure at the dew point: 17.625 × 15 = 264.375; 243.04 + 15 = 258.04; 264.375 / 258.04 = 1.0245; exp(1.0245) = 2.7856; e = 6.1094 × 2.7856 = 17.02 hPa.
- Compute the saturation vapor pressure at air temperature: 17.625 × 25 = 440.625; 243.04 + 25 = 268.04; 440.625 / 268.04 = 1.6439; exp(1.6439) = 5.175; es = 6.1094 × 5.175 = 31.62 hPa.
- Relative humidity = (17.02 / 31.62) × 100 = 53.83%.
The calculator rounds to one decimal place, giving 53.8%. This matches the block output for the default inputs.
Assumptions
- The Magnus formula assumes the air is in equilibrium with a flat surface of pure liquid water; it does not account for ice (relevant below 0 °C).
- The formula is an empirical fit, not an exact physical law; accuracy is within about 0.5% RH over the range −40 °C to +60 °C.
- It assumes standard atmospheric pressure (about 1013 hPa). At high altitudes, the same dew point gives a slightly different RH because total pressure affects the vapor pressure, but the error is small for most practical purposes.
- It assumes the dew point is measured correctly, which requires a clean, properly ventilated sensor.
How to Use the Result
Relative humidity tells you how close the air is to saturation. A value near 100% means the air cannot hold much more water, so condensation, fog, or dew is likely. A value below 30% feels dry and can cause static electricity, dry skin, and cracking wood. For human comfort, most people prefer 30–60%. For museums, archives, or woodworking, the target is often 40–55% to prevent damage. For indoor growing or greenhouses, 60–80% is common, but high humidity also encourages mold.
To use the result, first check whether you are measuring the air temperature in the same location and at the same time as the dew point. If you are using a psychrometer (wet-bulb and dry-bulb thermometers), the dew point is not directly read; you need a psychrometric chart or a separate calculation. Many online calculators accept either dew point or wet-bulb, so be sure you know which one you have.
Common Mistakes and Misconceptions
- Confusing dew point with relative humidity. A high dew point means the air has a lot of moisture, but the RH also depends on temperature. For example, a dew point of 15 °C gives 100% RH at 15 °C, but only 54% at 25 °C.
- Using the wrong temperature. The air temperature must be the dry-bulb temperature, not the wet-bulb or the temperature you feel due to wind chill or heat index.
- Mixing units. The Magnus formula requires Celsius. If you have Fahrenheit, convert first: °C = (°F − 32) × 5/9.
- Assuming RH is constant when temperature changes. If the moisture content stays the same, RH rises as temperature falls. This is why condensation appears on cold windows even when the room RH seems moderate.
- Rounding too early. If you round the exponential values to two decimals before dividing, you can get an error of several percent RH. Keep at least three significant figures in intermediate steps.
Limitations of the Formula
The Magnus formula is an approximation. Over the range −40 °C to +60 °C, it agrees with the more precise Goff-Gratch equation to within about 0.5% RH. Below −40 °C, the formula is less accurate because ice, not liquid water, is the stable phase, and the saturation vapor pressure over ice is lower. Some calculators switch to a different set of constants below 0 °C; this one does not, so it is best used for temperatures above freezing. Also, the formula assumes pure water; in the presence of dissolved salts (e.g., sea spray), the vapor pressure is lower, so the actual RH is slightly different.
For meteorological work, you may need the more complex Goff-Gratch equation or the WMO reference formulas. For everyday use, the Magnus formula is accurate enough.
How to Choose an Online RH Calculator
When you search for an online relative humidity calculator, check the following:
- What inputs does it accept? Some ask for dew point, others for wet-bulb temperature. Make sure you have the correct measurement.
- Does it show the formula? A transparent calculator will let you verify the math and understand the assumptions.
- What temperature range does it cover? If you need sub-zero readings, look for one that handles ice.
- Does it allow unit conversion? If you have Fahrenheit, the calculator should either accept it or you must convert manually.
- Is the output labeled clearly? The result should be a percentage, not a vapor pressure or a mixing ratio.
Frequently Asked Questions
What is the difference between relative humidity and dew point?
Dew point is the temperature to which air must cool to become saturated (100% RH) without changing its moisture content. It is an absolute measure of moisture in the air. Relative humidity is a relative measure: it depends on both the moisture content and the air temperature. For example, 20 °C air with a dew point of 10 °C has an RH of about 53%; if you warm that same air to 30 °C, the RH drops to about 28% even though the dew point stays 10 °C.
Can I calculate RH from wet-bulb and dry-bulb temperatures?
Yes, but it requires a psychrometric formula or chart. The wet-bulb temperature is the lowest temperature a wet wick can reach due to evaporative cooling. The difference between dry-bulb and wet-bulb gives a measure of dryness. Many online calculators accept wet-bulb and dry-bulb directly; if yours only accepts dew point, you can first convert wet-bulb to dew point using a psychrometric calculator.
Why does RH change when I heat or cool a room?
Heating a room raises the air temperature, which increases the saturation vapor pressure. If the moisture content (dew point) stays the same, the ratio e/es decreases, so RH drops. Cooling does the opposite. That is why cold winter air feels dry indoors after heating: the outside air may have high RH at 0 °C, but when warmed to 22 °C, the RH falls to around 20%.
What is a comfortable relative humidity level?
Most people feel comfortable between 30% and 60% RH. Below 30%, you may notice dry skin, itchy eyes, and static shocks. Above 60%, the air feels muggy, and mold growth becomes more likely. For health and building preservation, 40–50% is often recommended. The American Society of Heating, Refrigerating and Air-Conditioning Engineers (ASHRAE) suggests 30–60% for occupied spaces.
Does the calculator work for outdoor air at high altitude?
The Magnus formula assumes standard atmospheric pressure. At high altitude, the total pressure is lower, which slightly changes the relationship between dew point and RH. For most practical purposes, the error is less than a few percent RH up to about 3000 m. For precise meteorological work, use a formula that includes pressure or use a psychrometric chart for your altitude.
Why does my hygrometer read differently from the calculator?
Hygrometers can drift out of calibration, especially if they have been exposed to dust or chemicals. Also, the sensor may be near a heat source or in direct sunlight, giving a wrong temperature. Place the hygrometer away from drafts, heat, and moisture sources, and let it stabilize for at least 10 minutes. To check its accuracy, wrap it in a cloth dampened with water and wait; it should read near 100% RH.
Related
Formula used
in t | Air temperature | °C | 25 | -40 | 60 in td | Dew point | °C | 15 | -40 | 60 out rh | Relative humidity | % | 100 * exp((17.625 * td) / (243.04 + td) - (17.625 * t) / (243.04 + t)) | 1
Each line is one input (in, sel, list) or one result (out: label, unit, formula, decimals). How the calculators work
Method: the standard formula for this calculation with the constants and conversion factors written on the page, rounded as each result states. See method and constants, the disclaimer or report an error.
More in this section
- DNA Sequence Example Code: A Practical Guide0.2000 mol/L
- DNA to RNA in the Nucleus: How Transcription Works0.2000 mol/L
- RNA Sequence Reverse Complement Tool
- DNA Sequence Quality Q15: What It Means
- T4 RNA Ligase 2 Sequence & Function15,485.0 g/mol
- T7 RNA Polymerase Sequence: Full Gene & Key Features97.5 kDa