Air pressure at altitude calculator
At 1,500 m the standard atmosphere puts the air pressure at 845.562621 hPa, against 1013.25 hPa at sea level. Enter an altitude in metres, even below sea level, and get the pressure in hectopascals or inches of mercury. Free in your browser.
- Free
- Runs in your browser
- No sign-up
- Your data stays on your device
Run — free
Worked example
- Altitude
- 1,500
- Pressure
- 845.562621 hpa
- Pressure hpa
- 845.562621
- Pressure inhg
- 24.96945
- Precision
- 6
The air pressure at altitude calculator answers one precise question: given a height above sea level, what is the atmospheric pressure there? It applies the barometric formula from the International Standard Atmosphere, assuming standard sea-level conditions of 1013.25 hPa and 288.15 K with a constant tropospheric lapse rate, and returns the pressure in hectopascals or inches of mercury.
What the barometric formula actually computes
Air has weight, and the pressure at any point in the atmosphere is the weight of the column of air still above that point. Climb higher and there is less air above you, so pressure falls — but not linearly, because air is compressible and its density drops along with the pressure. The barometric formula captures this exactly for a layered atmosphere.
In the troposphere, where temperature decreases at a steady lapse rate of 0.0065 kelvin per metre, pressure follows a clean power law: P equals P0 times the quantity (1 minus L·h over T0) raised to the exponent g0·M divided by R·L. You supply the altitude in metres and receive the static pressure that a barometer would read under standard conditions, with no iterative solver and no approximation tables.
Because the model is closed form, the answer for a given altitude is always identical, which makes the result safe to cache, compare, and assert against in tests.
Inputs, units and how errors are handled
The only required input is the altitude, expressed in metres above sea level. Negative altitudes are deliberately accepted — sites such as the Dead Sea shore lie below sea level and correctly return pressures above the sea-level standard. An optional unit field selects the main result: hpa for hectopascals, which is numerically identical to millibars, or inhg for inches of mercury, the unit still used by aviation altimeters and United States weather reports.
The conversion uses the exact conventional factor of 33.8638866667 hectopascals per inch of mercury. An optional precision field, an integer from 0 to 15 with a default of 6, controls decimal places so that output is stable byte for byte across machines.
Where a standard-atmosphere pressure figure is useful
A standard-atmosphere pressure at altitude is the reference value behind a surprising amount of engineering. Drone and model-aircraft builders use it to sanity-check barometric altitude readings before a flight. Developers of hiking, cycling and fitness applications use it to convert raw pressure sensor output into elevation gain estimates, and to explain to users why a stormy day makes their watch think they climbed an extra floor.
Meteorology students compare the model value against observed station pressure to compute pressure altitude and density altitude for aircraft performance calculations. High-altitude baking and coffee roasting guides quote reduced boiling points that follow directly from the pressure this formula returns. It is also the right first step before more elaborate work: once you have the standard pressure you can layer on measured sea-level pressure corrections, humidity adjustments or a different lapse rate.
What you can do with it
Check a drone's barometric altimeter
Compare the pressure your flight controller reports at a known elevation against the standard-atmosphere value before trusting its altitude hold.
Estimate pressure for a hiking destination
Enter the elevation of a summit or mountain hut and get the expected hPa and inHg reading for acclimatization and weather planning.
Teach the standard atmosphere
Generate exact reference values for problem sets on the barometric formula, pressure altitude and the tropospheric lapse rate.
FAQ
What happens if the altitude is not a finite number?
NaN, Infinity, empty and unparseable values never reach the computation.
Does it account for real weather conditions?
No. It returns the standard-atmosphere value, which assumes standard sea-level conditions. Real measured pressure varies with weather systems by a few percent around this reference.
Are negative altitudes supported?
Yes. Altitudes below sea level are valid and return pressures above 1013.25 hPa, consistent with the standard model.
What is the air pressure at 1,500 metres?
Under the standard atmosphere it is 845.562621 hPa, or 24.96945 inches of mercury. That is the reading a barometer would show there on a standard day, not the pressure in today's weather.
Is a hectopascal the same as a millibar?
Yes, the two are numerically identical. If you need inches of mercury instead, as used by aviation altimeters and United States weather reports, the conversion uses 33.8638866667 hPa per inch.
Related tools
For developers — API access
Everything on this page is available programmatically. This section is for teams who want to wire it into their own systems; everyone else can just use the tool above.
API endpoint
Prefer to automate it? One authenticated POST creates the task; the result comes back by webhook or a signed link. The same capability also runs here on the web, by email and from Telegram — and soon from our app too.
Call it from your stack
curl -X POST https://api.kit.forhosting.com/phys/air-pressure-at-altitude \
-H "Authorization: Bearer $KIT_KEY" \
-H "Content-Type: application/json" \
-d '{"altitude":1500}'const res = await fetch("https://api.kit.forhosting.com/phys/air-pressure-at-altitude", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.KIT_KEY}`,
"Content-Type": "application/json"
},
body: JSON.stringify({
"altitude": 1500
})
});
const { task_id } = await res.json();import os, requests
res = requests.post(
"https://api.kit.forhosting.com/phys/air-pressure-at-altitude",
headers={"Authorization": f"Bearer {os.environ['KIT_KEY']}"},
json={
"altitude": 1500
},
)
task_id = res.json()["task_id"]<?php
$res = file_get_contents("https://api.kit.forhosting.com/phys/air-pressure-at-altitude", false, stream_context_create([
"http" => [
"method" => "POST",
"header" => "Authorization: Bearer " . getenv("KIT_KEY") . "\r\nContent-Type: application/json",
"content" => '{"altitude":1500}',
],
]));
$task = json_decode($res, true);body := bytes.NewBufferString(`{"altitude":1500}`)
req, _ := http.NewRequest("POST", "https://api.kit.forhosting.com/phys/air-pressure-at-altitude", body)
req.Header.Set("Authorization", "Bearer "+os.Getenv("KIT_KEY"))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)Example request
{
"altitude": 1500
}Example response
{
"task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
"type": "phys.air_pressure_at_altitude",
"status": "queued",
"_links": {
"result": "/tasks/tsk_…/result"
}
}The API is asynchronous: the call returns a task_id immediately and the result arrives by webhook. Polling is capped at 1 req/s per task.
Pricing
Published price — no tokens, no invented credits. A failed task is never charged.
Errors
| HTTP | Code | Meaning |
|---|---|---|
401 | unauthorized | Missing or invalid API key. |
402 | insufficient_balance | Your balance doesn't cover the task price. |
404 | unknown_type | That task type doesn't exist. |
429 | rate_limited | Too many requests. Use the webhook instead of polling. |
Technical notes
One call, one closed-form evaluation, deterministic every time — the same result in your browser for free as through the paid API.
What the barometric formula actually computes
This endpoint evaluates that expression directly with the International Standard Atmosphere constants: P0 of 1013.25 hectopascals, T0 of 288.15 kelvin, standard gravity of 9.80665 metres per second squared, and the molar mass of dry air.
Inputs, units and how errors are handled
It must be a finite number: NaN, positive or negative infinity, empty strings, and values that cannot be parsed as a decimal number are all rejected with an invalid_input error before any computation happens, and rejected calls are not billed. Regardless of your choice, the response always carries both pressure_hpa and pressure_inhg, so a single call serves mixed-unit pipelines.
Where a standard-atmosphere pressure figure is useful
The calculator runs on our edge with nothing stored, and the identical code runs free in your browser on this page, so you can prototype interactively and only pay $0.002 per call when you automate the lookup.
Technical questions
What does it cost?
$0.002 per request via the API. It is also free to run in your browser on this page — the same code executes in both places.
Which formula does it use?
The barometric formula of the International Standard Atmosphere troposphere: P = P0 · (1 − L·h/T0)^(g0·M/(R·L)), with P0 = 1013.25 hPa, T0 = 288.15 K and L = 0.0065 K/m.
Can I get inches of mercury instead of hectopascals?
Yes. Pass unit as inhg, or read the pressure_inhg field — the response always includes both units converted with the exact conventional factor.