# SQLite — SQLite / SpatiaLite

> SQLite (SQLite / SpatiaLite): Spatial extension to the SQLite database adding geometry columns, spatial SQL functions and R*Tree indexing in a single file. Specs, software and free sample files; convert SQLite to 39 formats online.

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



## What is a SQLite file?

SpatiaLite is an open-source extension to the SQLite database engine that adds spatial data types, metadata tables and a large library of SQL spatial functions. It is developed primarily by Alessandro Furieri. A SpatiaLite database is an ordinary single-file SQLite database, commonly using the .sqlite or .db extension. Geometry columns are stored as BLOBs in SpatiaLite's own binary encoding and registered in tables such as geometry_columns and spatial_ref_sys.

It is used for local spatial databases, data processing pipelines and as a lightweight alternative to a server database. Spatial queries can be accelerated with R*Tree indexes provided by SQLite, while geometric operations and reprojection rely on libraries such as GEOS and PROJ. Each geometry column has its own declared type and SRID, and separate tables act as layers. Full use requires software that loads the SpatiaLite extension; plain SQLite tools see geometries only as binary data.

SpatiaLite files are exchanged by GIS analysts, mobile app developers and data engineers who need a portable spatial database in one file. The .sqlite or .db extension does not show whether spatial support is present, so check for geometry_columns and spatial_ref_sys tables. Note the SRID and geometry type of each column, and confirm that the receiving software can load the SpatiaLite extension.

### Technical details

| | |
|---|---|
| Full name | SQLite / SpatiaLite |
| Data type | Vector · Database & container |
| File extension | .sqlite, .sqlite3, .db |
| Files | Single file |
| Media type | application/octet-stream |
| Geometry types | Point, MultiPoint, LineString, MultiLineString, Polygon, MultiPolygon, GeometryCollection, CircularString, CompoundCurve, CurvePolygon, MultiCurve, MultiSurface |
| Multiple layers | Yes |
| Mixed geometry in a layer | Yes |
| Attribute names | — |
| Coordinate system | Any (EPSG, ESRI, custom) |
| Converter support | Read & write |
| Typical software | QGIS, GDAL/OGR, spatialite_gui, FME, ArcGIS Pro |
| Specification | https://www.gaia-gis.it/fossil/libspatialite/index |

### Specifications & references

- https://www.gaia-gis.it/fossil/libspatialite/index
- https://gdal.org/en/stable/drivers/vector/sqlite.html

### Sample SQLite files — free download

- [Basemap (7 layers)](https://beta.mygeodata.cloud/static/landing/samples/v1/spatialite/st-helena-basemap.sqlite) — Multi-layer basemap of Saint Helena: island outline, land cover, waterways, 100 m contours, roads, Jamestown buildings and places. SpatiaLite database. (932 kB, EPSG:4326)
- [Places (points)](https://beta.mygeodata.cloud/static/landing/samples/v1/spatialite/st-helena-places.sqlite) — 58 places of Saint Helena (20 settlements, 17 peaks, 21 points of interest) with name, category, elevation from Copernicus DEM and OSM id. SpatiaLite database. (244 kB, EPSG:4326)

### Convert SQLite to other formats

- [SQLite to CSV](https://beta.mygeodata.cloud/converter/sqlite-to-csv)
- [SQLite to XLSX](https://beta.mygeodata.cloud/converter/sqlite-to-xlsx)
- [SQLite to GeoJSON](https://beta.mygeodata.cloud/converter/sqlite-to-geojson)
- [SQLite to GeoPDF](https://beta.mygeodata.cloud/converter/sqlite-to-geopdf)
- [SQLite to GPX](https://beta.mygeodata.cloud/converter/sqlite-to-gpx)
- [SQLite to SHP](https://beta.mygeodata.cloud/converter/sqlite-to-shp)
- [SQLite to KML](https://beta.mygeodata.cloud/converter/sqlite-to-kml)
- [SQLite to DXF](https://beta.mygeodata.cloud/converter/sqlite-to-dxf)
- [SQLite to KMZ](https://beta.mygeodata.cloud/converter/sqlite-to-kmz)
- [SQLite to GPKG](https://beta.mygeodata.cloud/converter/sqlite-to-gpkg)
- [SQLite to TopoJSON](https://beta.mygeodata.cloud/converter/sqlite-to-topojson)
- [SQLite to WKT](https://beta.mygeodata.cloud/converter/sqlite-to-wkt)
- [SQLite to MapInfo](https://beta.mygeodata.cloud/converter/sqlite-to-mapinfo)
- [SQLite to Parquet](https://beta.mygeodata.cloud/converter/sqlite-to-parquet)
- [SQLite to MIF](https://beta.mygeodata.cloud/converter/sqlite-to-mif)
- [SQLite to GML](https://beta.mygeodata.cloud/converter/sqlite-to-gml)
- [SQLite to SVG](https://beta.mygeodata.cloud/converter/sqlite-to-svg)
- [SQLite to DGN](https://beta.mygeodata.cloud/converter/sqlite-to-dgn)

## Frequently asked questions

### Why do I see only binary data in the geometry column?

Geometries are stored as BLOBs in SpatiaLite's own binary encoding. A plain SQLite tool cannot interpret them, so you need software that loads the SpatiaLite extension or a GIS application such as QGIS.

### How can I tell if a .db or .sqlite file is a SpatiaLite database?

Open it in a SQLite browser and look for the geometry_columns and spatial_ref_sys tables. If they are present and geometry columns hold BLOB data, the file is most likely a SpatiaLite database. Many other applications also use the .db extension for non-spatial data.

### How does SpatiaLite differ from GeoPackage?

Both are single-file SQLite-based formats that can hold many layers. They use different geometry encodings and metadata tables, so software may support one and not the other. SpatiaLite also provides a large library of SQL spatial functions through its extension.

### What is a SQLite file?

SpatiaLite is an open-source extension to the SQLite database engine that adds spatial data types, metadata tables and a large library of SQL spatial functions. It is developed primarily by Alessandro Furieri. A SpatiaLite database is an ordinary single-file SQLite database, commonly using the .sqlite or .db extension. Geometry columns are stored as BLOBs in SpatiaLite's own binary encoding and registered in tables such as geometry_columns and spatial_ref_sys.

It is used for local spatial databases, data processing pipelines and as a lightweight alternative to a server database. Spatial queries can be accelerated with R*Tree indexes provided by SQLite, while geometric operations and reprojection rely on libraries such as GEOS and PROJ. Each geometry column has its own declared type and SRID, and separate tables act as layers. Full use requires software that loads the SpatiaLite extension; plain SQLite tools see geometries only as binary data.

### How do I open a SQLite file?

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

### What can I convert SQLite to?

Popular conversions are CSV, XLSX, GeoJSON, GeoPDF, GPX and SHP. In total the Converter writes SQLite data to 39 formats.

### How do I create a SQLite file?

Convert existing data to SQLite — for example from CSV, GeoJSON, GeoPDF, XLSX and SHP. Upload the file, choose SQLite as output and download the result.

