Add elevation to GeoJSON files
Turn 2D GeoJSON into 3D: every position gets the ground elevation from the USGS 3DEP lidar model as its third coordinate. For data anywhere in Oregon.
Add elevation to a GeoJSON file
Elevate a File needs a pass: US$29 for 24 hours, US$99 for 30 days or US$399 for 12 months. It asks for one before the upload, then sends the file back with ground elevations.
Open Elevate a File →Why add elevation to GeoJSON?
GeoJSON is the everyday format of web maps and scripts, and most of it is 2D. With elevation in the coordinates you can draw profiles of lines, extrude or drape features in 3D, filter points by elevation, and hand richer data to GIS without a separate lookup.
Made for web mapping
The output is plain GeoJSON, with the elevation as the optional third element of each position that RFC 7946 allows. MapLibre, Leaflet, OpenLayers, QGIS and most scripting libraries read it as is.
{
"type": "Feature",
"properties": { "name": "Ridge walk" },
"geometry": {
"type": "LineString",
"coordinates": [
[-122.7559, 45.5401, 295],
[-122.7565, 45.5412, 292.6],
[-122.7571, 45.542, 298.8]
]
}
}The values above are ground elevations for three points in Portland’s West Hills, above NAVD 88; values in the file are in meters, the unit GeoJSON uses. Strictly, RFC 7946 describes the third value as height above the WGS 84 ellipsoid; the tool writes NAVD 88 elevations, which is what most maps and analyses want. Keep that in mind if you combine the file with ellipsoid heights.
Process your GeoJSON file
Ground elevations from USGS 3DEP lidar on every position, in seconds.
How it works
- Upload: open Elevate a File and, with a pass active, choose a
.geojsonor.jsonfile (up to 50 MB, all coordinates inside a square 3.7 miles on a side). - Processing: every position in every geometry is sampled from the 3DEP model on a grid laid over your data, interpolating between the four nearest cells. The grid has at most 1,024 samples across its longest side, so it is as fine as the source for a small dataset and coarser for a large one. The elevation becomes the third value, replacing any that was there.
- Download: the file comes back as
yourfile_elevation.geojson.
Supported geometry
- FeatureCollection, Feature or a bare geometry at the top level.
- Point and MultiPoint: each point.
- LineString and MultiLineString: every vertex.
- Polygon and MultiPolygon: every vertex of every ring.
- GeometryCollection: each member geometry.
Properties and any other members of your features are passed through unchanged. The output is pretty-printed with two-space indentation.
Use cases
Interactive trail maps
Add elevations to trail lines for a web map and draw a profile for each trail from the coordinates.
Property and parcel data
Give parcel corners or building footprints a ground elevation. Taxlot boundaries are assessment maps, not surveys.
Environmental monitoring
Add elevations to sampling points, stream survey sites or wells so you can sort and filter by elevation.
Tourism and education apps
Show viewpoints and points of interest, from the Oregon coast to the Cascades, with their ground elevation.
GIS analysis and research
Bring 3D points and lines into QGIS or a Python notebook ready for analysis.
Using the elevations
MapLibre GL
Read the third coordinate in expressions or in your own code to color, filter or label features by elevation.
Leaflet
Elevation-profile plugins for Leaflet that read the third coordinate can chart a line directly from the file.
Your own code
In JavaScript or Python the elevation is simply coordinates[i][2]; values in the file are in meters. Multiply by 3.28084 for feet.
Data quality and coverage
Ground elevations on this site come from the USGS 3D Elevation Program (3DEP) seamless bare-earth model: 3.3 ft per pixel where lidar has been flown and about 33 ft per pixel elsewhere, with elevations above NAVD 88. The data is in the public domain. Most of Oregon’s lidar was flown through the Oregon Lidar Consortium, run by DOGAMI, the Oregon Department of Geology and Mineral Industries. DOGAMI reports about 99% of Oregon covered by at least one lidar project. Values in the file are in meters (as USGS publishes them), to one decimal. More from the USGS 3D Elevation Program and DOGAMI’s lidar program.
File format notes
- Coordinates must be longitude, latitude in WGS84, as RFC 7946 requires.
- Positions outside Oregon, or where no elevation can be read, are written with longitude and latitude only.
- A
.jsonfile is treated as GeoJSON and returned as.geojson. - The file must be valid JSON; a parsing error is reported before anything is done.
Frequently asked questions
What coordinate system does the file need?
GeoJSON as defined in RFC 7946: longitude, latitude in decimal degrees (WGS84). The tool does not reproject, so a file in another coordinate system, such as Oregon Statewide Lambert feet, has to be converted to WGS84 first.
Will adding elevation break my code?
Usually not. A third value in a position is part of the GeoJSON standard, and most libraries accept it and ignore it when drawing in 2D. Code that assumes every position has exactly two numbers needs a check.
How large a file can I process?
Up to 50 MB, with every coordinate inside a square 3.7 miles on a side. Split larger datasets by area.
Is it accurate enough for engineering?
The values are bare-earth elevations from the USGS 3DEP model, 3.3 ft per pixel wherever lidar has been flown, with the accuracy of the lidar project behind each place. The tool reads that model on a grid capped at 1,024 samples across the longest side of your data, so a small dataset is sampled at the full detail of the source and one spread over several miles more coarsely. That is fine for planning and visualization. Where a legal or engineering decision depends on an elevation, get it surveyed.