Crime map API: put police incidents on a map

To build a crime map you need incident points with coordinates. Crime Data API's /v1/incidents returns them as GeoJSON for a radius of up to 5,000 m or a bounding box in 11 US cities, ready for Leaflet or Mapbox; the free plan covers 500 calls a month.

Try it free — no signup Get a free key

Last updated: 2026-11-07. External facts checked 2026-11-07.

Key facts

1. Fetch GeoJSON

curl "https://crimedata.dev/v1/incidents?lat=37.788&lon=-122.4075&radius_m=500&format=geojson&limit=200" -H "x-api-key: $CRIME_API_KEY"

For a map viewport use bbox=minLon,minLat,maxLon,maxLat instead of a radius. The response also carries source with the portal and licence, and warnings.

2. Draw it with Leaflet

The browser asks your own server, which holds the key and forwards the request:

const map = L.map('map').setView([37.788, -122.4075], 15);
L.tileLayer('https://tile.openstreetmap.org/{z}/{x}/{y}.png',
  { attribution: '© OpenStreetMap contributors' }).addTo(map);
const r = await fetch('/api/crimes?lat=37.788&lon=-122.4075');
const data = await r.json();               // GeoJSON FeatureCollection
L.geoJSON(data, { pointToLayer: (f, ll) => L.circleMarker(ll, { radius: 5 })
  .bindPopup(f.properties.category + ', ' + f.properties.occurred_at) }).addTo(map);
// your server, e.g. Node 18+
const u = 'https://crimedata.dev/v1/incidents?format=geojson&radius_m=500&limit=200&lat=' + lat + '&lon=' + lon;
const data = await (await fetch(u, { headers: { 'x-api-key': process.env.CRIME_API_KEY } })).json();

3. Show attribution and caveats

Print the city, source and licence from source under the map; several city licences require attribution. Locations come from each city's data and some are generalized, so do not present points as exact addresses; the density score method notes that sexual-offense locations are coarsened to about 100 m. Incidents are reports, not convictions.

Limits

Free keys are limited to 500 calls a month and a short per-key burst limit, with 429 and a Retry-After header when exceeded. Cache responses on your server instead of calling per pan or zoom. Ready-made city maps are on pages such as the Seattle crime map and New York City crime map; for listings see the real-estate guide and scorecard widget. Crime Data API is not a consumer reporting agency. Do not use it for tenant, employment, credit or insurance screening or any eligibility decision. Reported incidents are not convictions or a prediction of personal risk. Data is revised by the source and can be incomplete; keep the source attribution and check each city's licence for your use.

FAQ

Is there a free crime map API?

Crime Data API gives 500 free calls a month for incident points as GeoJSON in 11 US cities, which you can draw with Leaflet, Mapbox or any GeoJSON library. Paid plans are sold on RapidAPI.

Does the API return GeoJSON?

Yes. Add format=geojson to /v1/incidents to get a FeatureCollection of Point features with coordinates in [longitude, latitude] order, plus the source and licence for the city.

Can I call the API directly from browser JavaScript?

The API allows cross-origin GET requests, but a key placed in page code is public and can be used by anyone. Call it from your server and pass the result to the browser, or use a publishable widget key for the scorecard widget.

Can I use it on property listings?

You can show counts and points near a listing with the source attached, but never for tenant, buyer or other eligibility screening, and take care not to steer people toward or away from neighborhoods. See the terms on prohibited uses and the real-estate guide.

Related

Crime data API overview and pricing · Free crime data APIs compared · FBI Crime Data API key guide · FBI API alternative · SpotCrime alternative · CrimeoMeter alternative · Crime API reference

Crime Data API is not affiliated with, sponsored by, or endorsed by the FBI, GSA or api.data.gov, or UK police forces or data.police.uk. Names are used solely to identify the services described.