Elevation API

Easily get elevation from latitude and longitude.

The most complete and useful online elevation API:

  • Elevation API provides 3 modes (points, path and area), 3 formats (JSON, GeoTIFF and KML) and 2 units (meters and feet) to help you converting geographic coordinates to elevation data.
  • Tree height is removed from the elevation data to better match the terrain elevation.

Base URL

https://tessadem.com/api/elevation?parameters

Parameters

key (required)

The key that will identify you to the API.

Get an API key

locations (required)

One or more locations for which elevation data will be returned.
Each location must be made up of a latitude (between -80 and 84) and a longitude separated by a ,
Locations must be separated from each other by a |
The maximum number of locations per request is 512.
The maximum extent of locations per request is 5° latitude by 5° longitude.

mode (optional)

  • points (default)

    For each location provided, the corresponding elevation data will be returned.

  • path

    Provided locations define a path along which elevation data will be returned at regular intervals.
    The additional parameter samples determines the number of elevation data that must be returned.
    The maximum number of samples per request is 2,048.

  • area

    Provided locations define the southwest and northeast corners of an area within which elevation data will be returned at regular intervals.
    The additional parameters rows and columns determine the number of elevation data that must be returned.
    The maximum size of the area (i.e., rows multiplied by columns) per request is 16,384.

format (optional)

  • json (default)

    Elevation data will be returned in JSON format.

  • geotiff (only available in area mode)

    Elevation data will be returned in GeoTIFF format.

  • kml

    Elevation data will be returned in KML format.

unit (optional)

  • meters (default)

    Elevation data will be returned in meters.

  • feet

    Elevation data will be returned in feet.

Examples

  • Get the elevation data for location [44.690172, 4.806921] returned in meters as a JSON file:

    https://tessadem.com/api/elevation?key=KEY&locations=44.690172,4.806921

  • Get the elevation data for locations [44.690172, 4.806921] and [42.701059, 2.896646] returned in feet as a JSON file:

    https://tessadem.com/api/elevation?key=KEY&locations=44.690172,4.806921|42.701059,2.896646&unit=feet

  • Get 2,048 elevation data covering the path [46.2682, 6.0991], [44.6901, 4.8069], [42.701, 2.8966] returned in meters as a JSON file:

    https://tessadem.com/api/elevation?key=KEY&locations=46.2682,6.0991|44.6901,4.8069|42.701,2.8966&mode=path&samples=2048

  • Get 16,384 elevation data covering the area [42.701, 2.897], [46.268, 6.099] returned in meters as a GeoTIFF file:

    https://tessadem.com/api/elevation?key=KEY&locations=42.701,2.897|46.268,6.099&mode=area&rows=128&columns=128&format=geotiff

Response

Status code

  • 200 OK: the request was executed successfully.
  • 400 Bad Request: the request is malformed.
  • 414 Request-URI Too Long: the URL length must be less than 16,385 characters.
  • 429 Too Many Requests: the maximum number of 300 requests per minute has been exceeded.
  • 402 Payment Required: your request balance is insufficient.
  • 500 Internal Server Error: an unexpected error has occurred.

Headers

  • Request-Balance: your request balance after the current request has been executed.

Content

  • Success example:

    {
        "results": [
            {
                "latitude": 44.690172,
                "longitude": 4.806921,
                "elevation": 114.11919999948627
            },
            {
                "latitude": 42.701059,
                "longitude": 2.896646,
                "elevation": 39.394957439654924
            }
        ]
    }

    In area mode, elevation data will be returned as a 2-dimensional array representing rows and columns.

  • Error example:

    {
        "error": {
            "type": "INVALID_API_KEY",
            "message": "The API key is invalid."
        }
    }

Pricing

€12 per 12,000 requests (€0.001 per request).

For €12 you can get:

  • Up to 6,144,000 elevation data in points mode.
  • Up to 24,576,000 elevation data in path mode.
  • Up to 196,608,000 elevation data in area mode.

Buy API requests