Elevation API

The MapTiler Elevation API makes it possible to get accurate altitude above mean sea level for any place on Earth. See the intro to elevation to learn how it works and what you can use it for.

How to use the API

  • Directly from your web or backend applications.
  • Via the Elevation API client library, which wraps the API calls in ready-made functions for easier use in JavaScript. This is the best option if you don’t need a map.
  • With our complete map SDK for JavaScript. It provides an elevation profile module to add a control to your map which draws the elevation profile for a specified route.

Key

You need a MapTiler API key to use this service. Get it here and learn how to protect it.

You can get elevation for a single point or multiple points at once by providing their coordinates. Note that each pair of coordinates counts separately towards your API quota.


Elevation API reference

Scalar API Reference
v1.0
OpenAPI 3.1.0
Server:https://api.maptiler.com

MapTiler API

Client Libraries

Elevation

Get elevation

Get the elevation at given locations. If unit is omitted, elevation values are in meters.

Path Parameters
  • locations
    Type: string
    required

    List of lng,lat WGS 84 positions seperated by ; delimeter (Max 50 positions). Longitude values must be > -180 < 180. Latitudes must be >= -85 <= 85.

Query Parameters
  • unit
    Type: string enum

    Unit of the elevation.

    values
    • meters
    • feet
Responses
  • application/json
  • 400

    Out of bounds

Request Example for get/elevation/{locations}.json
curl 'https://api.maptiler.com/elevation/17,50;-133.5,58.39.json?key=YOUR_SECRET_TOKEN'
[
  [
    17,
    50,
    364.20001220703125
  ],
  [
    -133.5,
    58.39,
    1323.800048828125
  ]
]
Using the OpenAPI Specification?
Get the openapi.yaml
Was this helpful?
MapTiler Cloud API
Elevation API
Elevation API