Skip to content
Make with
A

Allmaps MapLibre

Georeferenced historical maps from IIIF

Maintained by Allmaps

Allmaps' MapLibre GL JS layer that warps scanned maps served over IIIF onto their geographic position in WebGL, straight from Georeference Annotations, with no pre-rendered tiles.

Live demo

Allmaps MapLibre running on MapLibre GL JS in your browser

Loading the map…

Demo code
import { WarpedMapLayer } from "@allmaps/maplibre";
import type { PluginDemo } from "../types";

export default {
  center: [-73.9337, 40.8011], // Harlem, New York
  zoom: 12.5,
  async run({ map }) {
    // A scanned historical map, served over IIIF and warped onto the map in WebGL
    // from its public Allmaps georeference annotation.
    const warpedMapLayer = new WarpedMapLayer();
    map.addLayer(warpedMapLayer as any); // the plugin's types target a newer maplibre-gl
    await warpedMapLayer.addGeoreferenceAnnotationByUrl(
      "https://annotations.allmaps.org/images/d180902cb93d5bf2",
    );
  },
} satisfies PluginDemo;