ForHosting KIT · Travel & geography

ECEF to geodetic converter

X 6378137, Y 0, Z 0 m is the point at 0° latitude, 0° longitude and 0 m height. Paste the XYZ metres from a GNSS receiver or a textbook and get geodetic latitude, longitude and ellipsoidal height on WGS84. Free in your browser.

  • Free
  • Runs in your browser
  • No sign-up
  • Your data stays on your device
Use it from WebAPIEmailTelegramApp soon
If you enter
X
6,378,137
Y
0
Z
0
You get
Latitude
0
Longitude
0
Height
0
Latitude
0

Earth-centered Earth-fixed coordinates store a point as a simple Cartesian triple X, Y, Z in meters relative to the Earth's center of mass, with the Z axis along the mean rotation pole and X through the equator at zero longitude. GNSS receivers, satellite ephemerides, inertial navigation filters, and many aerospace APIs emit positions in ECEF long before a map needs degrees. This ECEF to geodetic converter applies a deterministic iterative WGS84 solution: longitude comes from a two-argument arctangent of Y and X, while latitude and ellipsoidal height are refined with a short fixed-point loop on the prime vertical radius until the angle stabilizes. The result is geodetic latitude and longitude in degrees plus height above the WGS84 ellipsoid in meters—the same quantities you pass to maps, KML, and most GIS layers. The path uses only finite arithmetic, no network geocoding, no random jitter, and no date-dependent constants.

Where ECEF to geodetic conversion fits in GNSS, aerospace, and software

Aerospace students use the same conversion when a course introduces the difference between geocentric and geodetic latitude after spherical models and asks for the height of a given XYZ triple. Contest and interview practice often needs a fast offline source of lat lon height so candidates can verify hand calculations under time pressure. Product tools use the inverse when a support engineer pastes three large meter values from a ticket and needs geographic context in one step.

Pair it with UTM converters or haversine helpers when you are building a small lab of free, deterministic mapping utilities, and keep this tool focused on the single question: given ECEF X, Y, and Z in meters on WGS84, where is that point on Earth in geodetic degrees and height.

GNSS and receiver ECEF dumps to map degrees

Paste X, Y, Z meters from a GNSS library or RINEX-derived state and get WGS84 latitude, longitude, and ellipsoidal height for maps and KML.

GIS homework and ellipsoid demos

Check textbook ECEF-to-geodetic answers on the WGS84 ellipsoid without re-implementing the iterative latitude loop by hand.

What does the ECEF to geodetic converter cost?

It is free in your browser on this page.

Which datum and algorithm are used?

Longitude is closed-form atan2(Y,X); latitude and height use a short iterative fixed-point solve on the prime vertical radius N.

What units do x, y, z and height use?

All ECEF inputs are meters. Latitude and longitude are returned in decimal degrees; height is ellipsoidal height in meters above the WGS84 ellipsoid (not orthometric height above the geoid).

Why is the origin (0,0,0) rejected?

The Earth's center has no unique geodetic latitude or longitude.

How is this different from geocentric latitude?

Geocentric latitude is atan2(Z, p). Geodetic latitude is the angle of the ellipsoidal normal and differs by up to about eleven minutes of arc; this tool returns geodetic latitude and ellipsoidal height as used by GPS and most maps.

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.

POSThttps://api.kit.forhosting.com/geo/ecef-to-geodetic

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.

curl -X POST https://api.kit.forhosting.com/geo/ecef-to-geodetic \
  -H "Authorization: Bearer $KIT_KEY" \
  -H "Content-Type: application/json" \
  -d '{"x":6378137,"y":0,"z":0}'
{
  "x": 6378137,
  "y": 0,
  "z": 0
}
{
  "task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
  "type": "geo.ecef_to_geodetic",
  "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.

Per request$0.002

Published price — no tokens, no invented credits. A failed task is never charged.

HTTPCodeMeaning
401unauthorizedMissing or invalid API key.
402insufficient_balanceYour balance doesn't cover the task price.
404unknown_typeThat task type doesn't exist.
429rate_limitedToo many requests. Use the webhook instead of polling.

What ECEF XYZ means and what the response returns

In the WGS84 Earth-centered Earth-fixed frame, the origin sits at the Earth's center of mass, the Z axis points toward the Conventional Terrestrial Pole, the X axis lies in the equatorial plane toward the Greenwich meridian, and the Y axis completes a right-handed triad ninety degrees east of X. A surface point on the equator at zero longitude has X near the semi-major axis about six million three hundred seventy-eight thousand one hundred thirty-seven meters and Y and Z near zero; a point near the North Pole has large positive Z and small equatorial radius p equals the square root of X squared plus Y squared. Geodetic latitude is the angle between the equatorial plane and the ellipsoidal normal, not the geocentric angle from the center to the point, so converting XYZ requires the WGS84 flattening and an iterative or closed-form latitude solver rather than a single arctangent of Z over p. This tool returns latitude and longitude in degrees, ellipsoidal height in meters, short lat, lon, and h aliases, the echoed X Y Z inputs, the datum tag WGS84, ellipsoid constants a, inverse flattening, b, and e squared, a method tag for the iterative ECEF path, the iteration count used, the rounding precision, and a compact formula string for documentation. There is no reverse address lookup, no magnetic declination, and no network call: the engine either computes a finite geodetic triple or rejects the input with invalid_input. Rejected cases include missing coordinates, non-finite numbers, the exact origin zero zero zero which has no unique latitude or longitude, and an out-of-range precision field.

How fields are read and how the iterative WGS84 solve stays reproducible

Computation takes longitude as atan2 of Y and X, forms the equatorial radius p, seeds latitude from a geocentric estimate corrected by one minus eccentricity squared, then iterates latitude as atan2 of Z plus e squared times N times sin of latitude over p, where N is the prime vertical radius a over the square root of one minus e squared sin squared latitude. Height is p over cos latitude minus N, with a pole-safe branch that uses Z when cosine is tiny. The preferred fields are x, y, and z for the ECEF meters triple, with aliases X and ecef_x, Y and ecef_y, and Z and ecef_z so spreadsheets, query strings, and typed forms can reuse the same contract without renaming columns. Each coordinate may arrive as a JSON number or as a decimal string including scientific notation when finite; empty strings, Infinity, and NaN are rejected so a bad cell does not become a wrong meridian. An optional precision field, with aliases decimals and dp, chooses how many decimal places to expose for latitude, longitude, and height, defaulting to ten and capped at fifteen so JSON goldens stay stable across runtimes. Pair the free browser run on this page with the priced API when you need the identical mathematical result inside an automated pipeline without re-implementing WGS84 ECEF yourself.

Where ECEF to geodetic conversion fits in GNSS, aerospace, and software

On this page the work runs entirely in your browser; through the API each successful lookup costs $0.002, failed validation is not charged, and nothing is stored after the response returns. That split—free interactive exploration and a priced, identical API—matches the rest of the KIT tier-A catalog and lets you move from a classroom demo to an automated pipeline without changing the mathematical result.

Aerospace and inertial navigation fixtures

Convert Earth-fixed state vectors into geodetic lat/lon/height for unit tests of filters, simulators, and sensor fusion code.

Read the full KIT documentation →