Open source
Allmaps is open source, with libraries, plugins and APIs you can use in your own work.
Put historical maps on your website
Add georeferenced maps to MapLibre, OpenLayers or Leaflet. Each plugin loads Georeference Annotations and warps the original IIIF images in the browser.
Try it below: pan, zoom and change the opacity to compare the historical map with today’s streets.
Built with the Allmaps MapLibre plugin. Richards standard atlas of Holyoke, 1911: Norman B. Leventhal Map & Education Center at the Boston Public Library, via Digital Commonwealth.
// Imports and worker setup · 7 lines
import { Map, setWorkerUrl } from 'maplibre-gl'
import { WarpedMapLayer } from '@allmaps/maplibre'
import 'maplibre-gl/dist/maplibre-gl.css'
import workerUrl from 'maplibre-gl/dist/maplibre-gl-worker.mjs?worker&url'
setWorkerUrl(workerUrl)
const map = new Map({
container: 'map',
style: 'https://basemaps.cartocdn.com/gl/voyager-gl-style/style.json',
maxPitch: 0
})
const warpedMapLayer = new WarpedMapLayer()
const annotationUrl = 'https://annotations.allmaps.org/manifests/071c6ba31f9c88d4'
map.on('load', async () => {
map.addLayer(warpedMapLayer)
await warpedMapLayer.addGeoreferenceAnnotationByUrl(annotationUrl)
const bounds = warpedMapLayer.getBounds()
if (bounds) map.fitBounds(bounds, { padding: 30 })
})
Build with the individual parts
Use Allmaps’ TypeScript libraries in your own projects. Work with annotations, transform coordinates or render maps.
@allmaps/annotationRead and create Georeference Annotations.
@allmaps/transformTransform image pixels into geographic coordinates and back.
@allmaps/projectTransform coordinates using map projections.
@allmaps/renderRender georeferenced maps in the browser or on a server.
import { GcpTransformer } from '@allmaps/transform'
const gcps = [
{ resource: [0, 0], geo: [4.9, 52.38] },
{ resource: [1000, 0], geo: [4.92, 52.38] },
{ resource: [0, 1000], geo: [4.9, 52.36] }
]
const transformer = new GcpTransformer(gcps)
// Image pixels
const point = [500, 500]
console.log(transformer.transformToGeo(point))
// Longitude, latitude
// ≈ [4.91, 52.37]Connect your tools and workflows
Allmaps APIs
Retrieve Georeference Annotations, query maps and connect Allmaps to your collection systems. The API documentation explains the available endpoints and authentication.
Explore the APIsAllmaps CLI
Work with maps from your terminal. Parse annotations, transform coordinates and process IIIF resources in scripts and repeatable workflows.
Get started with Allmaps CLINeed data for your project? Download the open georeference dataset to explore and reuse maps across collections.
Explore the source code
The whole Allmaps project is open source. You can read the code, adapt it to your needs and contribute improvements.
Licenses
The core libraries and mapping plugins use the MIT license. Applications and services have their own licenses, listed in each component’s repository. Public georeference data is released under CC0.
Use of the hosted Allmaps services is covered by the Terms & Usage.
Help improve Allmaps
Report a bug, suggest an improvement, contribute code or help with the documentation. You can join the discussion on GitHub or get in touch.
Explore the code on GitHub