# DEM — USGS ASCII DEM (and CDED)

> DEM (USGS ASCII DEM (and CDED)): Legacy text-based elevation format from the U.S. Geological Survey, also used for Canadian Digital Elevation Data (CDED). Specs, software and free sample files; convert DEM to 50 formats online.

- Page: https://beta.mygeodata.cloud/formats/dem



## What is a DEM file?

The USGS ASCII DEM format was developed by the U.S. Geological Survey to distribute digital elevation models, most commonly 7.5-minute quadrangles in UTM coordinates and 1-degree blocks in geographic coordinates. Natural Resources Canada distributed Canadian Digital Elevation Data (CDED) in the same format. Although these products have largely been superseded by newer elevation datasets, the format is still encountered in archives and older projects.

A file is organised into logical records stored in fixed-length blocks. Record A is a header describing the quadrangle, projection, horizontal datum, units, ground resolution and elevation scaling. Type B records hold the elevations as profiles running from south to north, and an optional Record C reports accuracy statistics. Elevations are stored as integers that are scaled by a header factor, and the units can be metres or feet. The format holds a single band. It is plain ASCII but uses Fortran-style numeric formatting, which makes it awkward to edit by hand.

USGS ASCII DEM files mostly come from US quadrangle archives and from Canadian CDED downloads, and they are usually exchanged by surveyors, hydrologists and anyone maintaining older terrain projects. Check the elevation units (metres or feet), the vertical scaling factor and the horizontal datum in the header before combining files. Neighbouring quadrangles often have different projections or zones, so they may need reprojection first.

### Technical details

| | |
|---|---|
| Full name | USGS ASCII DEM (and CDED) |
| Data type | Raster · Elevation & grid |
| File extension | .dem |
| Files | Single file |
| Media type | — |
| Bands | Single-band elevation. |
| Pixel types | Integer or float (text) |
| Compression | None |
| Coordinate system | Any (georeferenced) |
| Converter support | Read & write |
| Typical software | QGIS, GDAL/OGR, Global Mapper, ArcGIS Pro, FME, MicroDEM |
| Specification | https://gdal.org/en/stable/drivers/raster/usgsdem.html |

### Specifications & references

- https://gdal.org/en/stable/drivers/raster/usgsdem.html

### Sample DEM files — free download

- [Elevation (30 m, UTM)](https://beta.mygeodata.cloud/static/landing/samples/v1/usgsdem/st-helena-dem.dem) — Copernicus DEM GLO-30 elevation model of Saint Helena (0–812 m), a surface model including trees and buildings; sea = 0 m. Resampled to 30 m in UTM zone 30S (604×508 px). USGS DEM (ASCII, Int16). (2.4 MB, EPSG:32730)

### Convert DEM to other formats

- [DEM to TIF](https://beta.mygeodata.cloud/converter/dem-to-tif)
- [DEM to JPG](https://beta.mygeodata.cloud/converter/dem-to-jpg)
- [DEM to PNG](https://beta.mygeodata.cloud/converter/dem-to-png)
- [DEM to KMZ raster](https://beta.mygeodata.cloud/converter/dem-to-kmz-raster)
- [DEM to HFA](https://beta.mygeodata.cloud/converter/dem-to-hfa)
- [DEM to XYZ](https://beta.mygeodata.cloud/converter/dem-to-xyz)
- [DEM to GRD](https://beta.mygeodata.cloud/converter/dem-to-grd)
- [DEM to MBTiles raster](https://beta.mygeodata.cloud/converter/dem-to-mbtiles-raster)
- [DEM to GeoPDF raster](https://beta.mygeodata.cloud/converter/dem-to-geopdf-raster)
- [DEM to JP2](https://beta.mygeodata.cloud/converter/dem-to-jp2)
- [DEM to BIL](https://beta.mygeodata.cloud/converter/dem-to-bil)
- [DEM to netCDF raster](https://beta.mygeodata.cloud/converter/dem-to-netcdf-raster)
- [DEM to ENVI](https://beta.mygeodata.cloud/converter/dem-to-envi)
- [DEM to AAIGrid](https://beta.mygeodata.cloud/converter/dem-to-aaigrid)
- [DEM to GIF](https://beta.mygeodata.cloud/converter/dem-to-gif)
- [DEM to GPKG raster](https://beta.mygeodata.cloud/converter/dem-to-gpkg-raster)
- [DEM to BMP](https://beta.mygeodata.cloud/converter/dem-to-bmp)
- [DEM to RST](https://beta.mygeodata.cloud/converter/dem-to-rst)

## Frequently asked questions

### Is a .dem file always a USGS ASCII DEM?

No. The .dem extension is also used by other elevation formats, such as SDTS DEM and some game or terrain-specific files. A USGS ASCII DEM is a text file that begins with a Record A header, so you can usually recognise it by opening it in a text editor.

### Why do the elevation values look wrong after opening the file?

The elevations are stored as integers and scaled by a factor in the header, and the units may be feet rather than metres. If software ignores the scaling or the unit code, values will be off. Check the header and the vertical units in the converted result.

### How does USGS ASCII DEM differ from Esri ASCII Grid?

Esri ASCII Grid is a simple text grid with a short header and rows of values. USGS ASCII DEM uses fixed-length logical records with Fortran-style numbers, stores profiles running south to north, and includes projection, datum and accuracy information in its records.

### What is a DEM file?

The USGS ASCII DEM format was developed by the U.S. Geological Survey to distribute digital elevation models, most commonly 7.5-minute quadrangles in UTM coordinates and 1-degree blocks in geographic coordinates. Natural Resources Canada distributed Canadian Digital Elevation Data (CDED) in the same format. Although these products have largely been superseded by newer elevation datasets, the format is still encountered in archives and older projects.

A file is organised into logical records stored in fixed-length blocks. Record A is a header describing the quadrangle, projection, horizontal datum, units, ground resolution and elevation scaling. Type B records hold the elevations as profiles running from south to north, and an optional Record C reports accuracy statistics. Elevations are stored as integers that are scaled by a header factor, and the units can be metres or feet. The format holds a single band. It is plain ASCII but uses Fortran-style numeric formatting, which makes it awkward to edit by hand.

### How do I open a DEM file?

DEM files can be opened in QGIS, GDAL/OGR, Global Mapper, ArcGIS Pro and FME. Without any software you can preview and convert them online in MyGeodata Cloud.

### What can I convert DEM to?

Popular conversions are TIF, JPG, PNG, KMZ raster, HFA and XYZ. In total the Converter writes DEM data to 50 formats.

### How do I create a DEM file?

Convert existing data to DEM — for example from TIF, KMZ raster, JPG, HGT and HFA. Upload the file, choose DEM as output and download the result.

