LinuxCommandLibrary

gdalinfo

displays raster dataset information

TLDR

Show raster information

$ gdalinfo [file.tif]
copy
Show statistics
$ gdalinfo -stats [file.tif]
copy
Show in JSON format
$ gdalinfo -json [file.tif]
copy
Check specific dataset
$ gdalinfo [file.vrt]
copy
Show metadata
$ gdalinfo -mm [file.tif]
copy

SYNOPSIS

gdalinfo [options] datasetname

DESCRIPTION

gdalinfo displays information about raster datasets. It shows format, dimensions, coordinate system, bands, and metadata for geospatial raster files.
The tool reads header information and optionally computes statistics. It supports hundreds of raster formats through GDAL drivers.
gdalinfo is the first step in understanding and validating geospatial raster data.

PARAMETERS

DATASETNAME

Input raster file.
-json
Output as JSON.
-stats
Compute and display statistics.
-mm
Compute min/max values.
-hist
Compute histogram.
-nogcp
Suppress GCP output.
-nomd
Suppress metadata output.
--help
Display help information.

CAVEATS

Statistics computation reads entire file. Some formats have limited metadata. Large files may be slow.

HISTORY

gdalinfo is part of GDAL (Geospatial Data Abstraction Library), providing raster inspection capabilities across hundreds of formats.

SEE ALSO

> TERMINAL_GEAR

Curated for the Linux community

Copied to clipboard

> TERMINAL_GEAR

Curated for the Linux community