Catalog/geo-geodetic-to-ecef

Geospatial

Lat/lon/height to ECEF API

Converts geodetic coordinates (lat, lon, ellipsoidal height) to Earth-Centered Earth-Fixed (ECEF) Cartesian X/Y/Z meters on the WGS-84 ellipsoid, plus the prime-vertical radius. Answers 'What are the ECEF coordinates of this position?', 'How do I convert GPS lat/lon to 3D Cartesian?'.

Price$0.06per request
MethodPOST
Route/v1/geo/geodetic-to-ecef
StatusLive
MIME typeapplication/json
Rate limit120/minute
Cache0s public
geogisecefgeodeticcartesianwgs84xyzgpscoordinate-transform
API URLhttps://x402.hexl.dev/v1/geo/geodetic-to-ecef
Integration docs
Example request
{
  "latitude": 51.5074,
  "longitude": -0.1278,
  "heightM": 0
}
Example response
{
  "latitude": 51.5074,
  "longitude": -0.1278,
  "heightM": 0,
  "ellipsoid": "WGS-84",
  "ecef": {
    "x": 3977994.274,
    "y": -8873.053,
    "z": 4968874.937
  },
  "primeVerticalRadiusM": 6391255.69,
  "interpretation": "ECEF coordinates (meters): X=3977994.274, Y=-8873.053, Z=4968874.937. The origin is Earth's center; +X points to (0°N,0°E), +Z to the north pole."
}
Input schema
{
  "type": "object",
  "required": [
    "latitude",
    "longitude"
  ],
  "properties": {
    "latitude": {
      "type": "number",
      "examples": [
        51.5074
      ]
    },
    "longitude": {
      "type": "number",
      "examples": [
        -0.1278
      ]
    },
    "heightM": {
      "type": "number",
      "examples": [
        0
      ]
    }
  }
}
Output schema
{
  "type": "object",
  "additionalProperties": true
}