ECEF to Geodetic Converter

Enter ECEF X, Y, Z in meters to convert to latitude, longitude, and altitude.

How it is calculated

X, Y and Z are metres in the WGS 84 Earth-centred, Earth-fixed frame (X through the equator at the prime meridian, Y 90° east, Z through the north pole). The tool uses the WGS 84 ellipsoid with a = 6,378,137 m and flattening f = 1/298.257223563. Longitude is atan2(Y, X). Latitude comes from Bowring's closed-form formula using p = √(X² + Y²) and an auxiliary angle θ = atan2(Z·a, p·b). Altitude is the height above the ellipsoid, p / cos φ − N, where N is the prime-vertical radius of curvature (near the poles the Z-based form is used instead). On the polar axis the longitude is shown as 0° and latitude as ±90°. The point X = Y = Z = 0 has no result. Altitude is relative to the ellipsoid, not to mean sea level.

Worked example

Take X = 4,216,608 m, Y = 2,335,226 m, Z = 4,163,176 m. Longitude = atan2(2,335,226, 4,216,608) = 28.978396°. The horizontal distance from the axis is p = √(4,216,608² + 2,335,226²) ≈ 4,820,069 m. Bowring's formula turns p and Z into a latitude of 41.008201°. Subtracting the radius of curvature N from p / cos φ leaves an altitude of 99.85 m. The coordinates were rounded to whole metres, so the height differs a little from the 100 m they were built from.

Try this example →

Common mistakes

  • Entering kilometres or feet. The three fields are metres; a value like 4216.6 is read as 4,216.6 m and puts the point near the centre of the Earth.
  • Using values that are not ECEF, such as latitude and longitude in the X and Y boxes. The inputs must be Cartesian distances measured from the Earth's centre.
  • Expecting a result for points deep inside the Earth. Points deep inside the Earth (within about 1,000 km of the centre) have no geodetic position, so the tool shows no result for them. Use real surface or orbital positions.
  • Reading the altitude as height above sea level. It is height above the WGS 84 ellipsoid, which can differ from the geoid by tens of metres.
  • Mixing up the sign of X, Y or Z. A negative X with Y = 0 gives a longitude of 180°, and a negative Z gives a southern latitude.

About this calculator

ECEF (Earth-Centered, Earth-Fixed) coordinates locate a point in space as X, Y, Z Cartesian distances from the Earth's center, the native format used internally by GPS satellites and receivers. Because ECEF coordinates aren't intuitive for humans, they're typically converted to geodetic coordinates — latitude, longitude, and altitude on the WGS84 reference ellipsoid — using Bowring's method, a closed-form formula that gives the answer in a single pass (no iteration) and accounts for the Earth's slight equatorial bulge rather than treating it as a perfect sphere.

This conversion runs constantly inside GPS/GNSS receivers, satellite navigation systems, and geospatial engineering software, translating the raw Cartesian positioning data satellites transmit into the lat/lon/altitude readout that maps, navigation apps, and surveying equipment actually display to users.

Was this helpful?

You can pick up to 3 reactions.

Comments (1)

  • Editorial team

    A quick check on any result: work out the straight-line distance from the origin, the square root of X squared plus Y squared plus Z squared, and subtract about 6,371,000 m. The answer should land within roughly 21 km of the altitude shown, because the WGS 84 ellipsoid radius runs from about 6,357 to 6,378 km. For example, a point 26,560,000 m from the centre sits about 20,182 km up. Where do your coordinates come from: a receiver log, a satellite file, or a textbook?

Popular calculators

All Calculators