Terrain Analysis

Contour Lines Generator

Draw an area on the map to trace contour lines at the interval you choose, with index contours and labels, and download them as DXF, GeoJSON or KML.

1. Study area

Zoom in to your study area and draw a rectangle or polygon. Without a mouse, Use Visible Area takes the area currently on screen.

2. Contour settings

3. Export

Data Source and Accuracy

Elevation data: AWS Terrain Tiles (Mapzen/Tilezen; SRTM, GMTED2010, ETOPO1 and other sources), roughly 10-30 m resolution. The contours are for preliminary studies and must not be used for design or setting out. Elevation tiles come from AWS and basemap tiles from Esri or OpenStreetMap servers; these requests contain only tile numbers. The boundary you draw and the files you create are not sent to any server.

Related Tools

What contour lines are and what this tool produces

A contour line joins points of equal elevation. Contours are drawn at a fixed interval, for example every 5 metres; where they bunch together the ground is steep, and where they spread apart it is gentle.

This tool traces contour lines for the area you draw, entirely in your browser, and writes them to files that CAD and GIS software can open directly. It is built for preliminary work: discussing a route or layout idea in a design office, comparing the relief of candidate solar or wind sites, or showing the general shape of the land at proposal stage.

How to use it

  1. Zoom in to your study area. If you know the coordinates, type the latitude and longitude into "Go to location".
  2. Draw a rectangle or a polygon. Finish a polygon by clicking its first vertex again. When working from the keyboard, "Use Visible Area" takes the area on screen.
  3. The tool divides the area into a regular grid, reads the elevation at every node and traces the contours. With the interval set to "Automatic", it suggests one based on the size of the area and its elevation range.
  4. Changing the interval, index contour spacing or smoothing updates the lines without downloading data again. Index contours are drawn thicker on the map and labelled with their elevation.
  5. Pick a coordinate system and DXF format and download the file. You can also save the same result as GeoJSON or KML, or export the grid elevations as CSV.

Contour interval and index contours

Choosing an interval is a balance between legibility and the detail the data can actually carry. For a few hectares, 1-2 m usually reads well; for a few square kilometres, 5-10 m; for large mountainous areas, 20 m or more. The automatic suggestion picks the finest interval that keeps the number of levels to about forty. Index contours are every Nth line drawn thicker; by default every fifth line is an index contour, so at a 5 m interval the multiples of 25 m are emphasised. The distinction is kept in the DXF as two separate layers.

Export formats and coordinate systems

In the DXF each contour is an LWPOLYLINE that stores its level as the ELEVATION value. Index contours are on CONTOUR_MAJOR, intermediate contours on CONTOUR_MINOR, labels on CONTOUR_LABEL and the study boundary on BOUNDARY. The boundary sits at elevation 0, so leave that layer out when you build a surface from the contours. The default format is AutoCAD 2000; the R12 option writes contours as POLYLINE entities with elevation for older software. Coordinates can be WGS84 / UTM with the zone chosen automatically, the Turkish ITRF96 or ED50 3-degree TM systems with the central meridian taken from the longitude of the area, or WGS84 latitude/longitude. The ED50 conversion uses the EPSG:1784 "ED50 to WGS 84 (30)" parameters, which carry an uncertainty of their own in the order of a metre. The epoch difference between ITRF96 and WGS84 is below a metre and is ignored. In the DXF, X is easting and Y is northing.

Data and method

Elevations are read at zoom level 14 from AWS Terrain Tiles (Mapzen/Tilezen), published as open data. In many regions, including Turkey, the underlying data comes largely from global models such as SRTM with a resolution of about 30 m. The drawn area is split into a grid with a spacing of at least 10 m; the node count is capped at about 62,500, so the spacing grows with the area, and areas above 100 km² are not accepted. Contours are traced with the marching squares method: in each grid cell the points where the line crosses the cell edges are found by linear interpolation, ambiguous cells are resolved using the cell average, and the pieces are joined into continuous lines. Optional smoothing uses Chaikin's corner-cutting algorithm and only improves the appearance. Finally the lines are clipped to your polygon.

Coordinate conversion runs on proj4js 2.9.0 (MIT licence); icons come from Lucide (ISC licence). Basemaps are provided by Esri and OpenStreetMap contributors. Open-source libraries used and their licences: Data Sources.

Accuracy limits

For professional projects

Rodosto Teknoloji works on geospatial projects that involve high-resolution elevation models, drone and satellite imagery and GIS platforms. You can find more about the company on the Rodosto Teknoloji website or reach the team through the contact page.

Frequently Asked Questions

Can these contours be used for design or setting out?

No. The contours are derived from a global elevation model with a resolution of roughly 10-30 m and are meant for preliminary studies and rough planning. Detailed design, earthwork quantities, zoning and setting out require a field survey with GNSS, a total station or drone photogrammetry.

Will the DXF open in AutoCAD and other CAD software?

Yes. The default output is AutoCAD 2000 (R2000) DXF; each contour is an LWPOLYLINE that carries its level as the ELEVATION value, with index and intermediate contours on separate layers. An R12 option that writes POLYLINE entities is available for older software.

Which contour interval should I choose?

The automatic option suggests 1, 2, 5, 10, 20, 50 or 100 m based on the size of the area and its elevation range. The source data is not accurate enough vertically to support 1-2 m intervals, so use those only for visual density.

Which coordinate system should I use?

Outside Turkey, WGS84 / UTM is the usual choice and the zone is picked automatically. Turkish projects normally use ITRF96 3-degree TM, and the tool selects the central meridian from the longitude of the area. Choose WGS84 latitude/longitude only if you need geographic coordinates; CAD measurements work best in a metric system.