# Rasterlite — Rasterlite (SQLite raster tiles)

> Rasterlite (Rasterlite (SQLite raster tiles)): Legacy SpatiaLite-based format storing tiled, compressed raster imagery and pyramids inside a single SQLite database. Specs, software and free sample files; convert Rasterlite to 50 formats online.

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



## What is a Rasterlite file?

Rasterlite is a format for storing raster imagery inside an SQLite database. It was developed by Alessandro Furieri as a companion to the SpatiaLite spatial extension. A coverage is split into tiles that are stored as compressed BLOBs, typically PNG for lossless or JPEG for lossy compression. The tiles are held in a pair of tables: one contains the tile images and the other contains tile geometries and metadata. Reduced-resolution pyramid levels can be stored in the same tables to speed up display at small scales.

Georeferencing and the spatial reference system are recorded through SpatiaLite metadata. The whole dataset is a single portable file, which makes it convenient for distributing basemaps and orthophotos. The format is limited to 8-bit imagery such as grayscale, paletted and RGB data, so it is unsuitable for elevation or scientific data. Rasterlite has been superseded by RasterLite2 and by GeoPackage, and it is now mainly encountered in older datasets.

Rasterlite files usually come from older SpatiaLite-based workflows, where basemaps or orthophotos were packed into one SQLite database for delivery. Because the .sqlite extension is shared with many unrelated databases, check that the file actually holds Rasterlite tile tables before relying on it. Only 8-bit imagery is supported, and georeferencing depends on the SpatiaLite metadata being present and intact.

### Technical details

| | |
|---|---|
| Full name | Rasterlite (SQLite raster tiles) |
| Data type | Raster · Tiles & pyramids |
| File extension | .sqlite |
| Files | Single file |
| Media type | application/x-sqlite3 |
| Bands | 1–4 (grayscale, RGB, RGBA). |
| Pixel types | 8-bit unsigned integer |
| Compression | PNG (lossless), JPEG (lossy) |
| Coordinate system | Any (georeferenced) |
| Converter support | Read & write |
| Typical software | SpatiaLite, GDAL/OGR, QGIS |
| Specification | https://www.gaia-gis.it/fossil/librasterlite/home |

### Specifications & references

- https://www.gaia-gis.it/fossil/librasterlite/home
- https://gdal.org/en/release-3.10/drivers/raster/rasterlite.html

### Sample Rasterlite files — free download

- [Sentinel-2 true colour (20 m)](https://beta.mygeodata.cloud/static/landing/samples/v1/rasterlite/st-helena-sentinel2-rgb.sqlite) — Sentinel-2 L2A true-colour image of Saint Helena from 20 April 2024 (S2A_29LRC_20240420_0_L2A), 8-bit RGB with a contrast stretch, 20 m pixels (906×762), UTM zone 30S. Rasterlite (SpatiaLite) database with JPEG tiles. (1.1 MB, EPSG:32730)

### Convert Rasterlite to other formats

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

## Frequently asked questions

### Why does my .sqlite file not open as a raster?

The .sqlite extension is used by many kinds of SQLite databases. A file is only read as Rasterlite if it contains the expected pair of tile and metadata tables with SpatiaLite georeferencing information. Otherwise it may be a vector SpatiaLite database or a different application's data.

### Can Rasterlite store elevation or scientific raster data?

No. Rasterlite is limited to 8-bit unsigned imagery with 1 to 4 channels, such as grayscale, paletted, RGB or RGBA. Elevation models and other floating-point or 16-bit data need a different format.

### How does Rasterlite differ from GeoPackage rasters?

Both keep tiles as image BLOBs inside an SQLite file. Rasterlite relies on SpatiaLite metadata, while GeoPackage is an open standard with its own defined tile tables. GeoPackage is more widely supported and has largely replaced Rasterlite for new data.

### What is a Rasterlite file?

Rasterlite is a format for storing raster imagery inside an SQLite database. It was developed by Alessandro Furieri as a companion to the SpatiaLite spatial extension. A coverage is split into tiles that are stored as compressed BLOBs, typically PNG for lossless or JPEG for lossy compression. The tiles are held in a pair of tables: one contains the tile images and the other contains tile geometries and metadata. Reduced-resolution pyramid levels can be stored in the same tables to speed up display at small scales.

Georeferencing and the spatial reference system are recorded through SpatiaLite metadata. The whole dataset is a single portable file, which makes it convenient for distributing basemaps and orthophotos. The format is limited to 8-bit imagery such as grayscale, paletted and RGB data, so it is unsuitable for elevation or scientific data. Rasterlite has been superseded by RasterLite2 and by GeoPackage, and it is now mainly encountered in older datasets.

### How do I open a Rasterlite file?

Rasterlite files can be opened in SpatiaLite, GDAL/OGR and QGIS. Without any software you can preview and convert them online in MyGeodata Cloud.

### What can I convert Rasterlite to?

Popular conversions are TIF, HFA, JPG, XYZ, JP2 and BIL. In total the Converter writes Rasterlite data to 50 formats.

### How do I create a Rasterlite file?

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

