Map the Block › Data API

Map the Block Data API

The figures behind the map as plain JSON: census, reported crime, hazards, health, elections and nearby facilities for any U.S. county, state, congressional district or point. Every value comes from an official public source, with the source, period and licence included in the response.

Free to start: 1,000 calls a month with a free key. Paid plans add volume, bulk downloads and commercial use.

Quick start

  1. Log in or create a free account, then make a key in Your keys below.
  2. Call the API with the key in the X-API-Key header.
curl -H "X-API-Key: YOUR_KEY" "https://maptheblock.com/api/v1/point?lat=43.0747&lng=-89.3841&near=health_centers"

That returns the county (Dane County, WI), state and congressional district for the point, every county and state dataset below, and the health centers within 5 miles.

Endpoints

CallWhat you get
GET /api/v1/point?lat=&lng=County, state and district for a point, with all their datasets. Add near=a,b, radius (miles, up to 25) and limit (up to 50) for nearby facilities.
GET /api/v1/county/{fips}All county datasets. Use the 5-digit FIPS code, e.g. 55025.
GET /api/v1/state/{abbr}All state datasets, e.g. WI or 55.
GET /api/v1/district/{geoid}Your U.S. House member and campaign money, e.g. 5502 (state FIPS + district).
GET /api/v1/tribal/{geoid}A tribal area (reservation, Alaska Native village area, Oklahoma tribal area, Hawaiian home land) with its census figures, e.g. 2430 for the Navajo Nation. Point lookups also say which tribal area a point is in.
GET /api/v1/nearby?lat=&lng=&dataset=The closest points from one dataset, with distance in miles.
GET /api/v1/bulk/{dataset}.csvA whole dataset in one file (.json or .csv for areas, .geojson or .csv for points). Developer plan and up.
GET /api/v1/datasetsThe dataset list with source, period, licence and last update. No key needed.
GET /api/v1/usageYour plan and calls this month.

Every keyed response carries X-RateLimit-Remaining-Month. Errors come back as JSON with an error message. CORS is open, but keep keys on your server, not in public web pages.

Datasets

Loading the list…

Not in the API, by design: letter grades, scores, rankings, race, ethnicity, religion, birthplace, language, disability, sex-offender and gang data. Datasets whose licence doesn't allow commercial reuse are left out too.

Plans

Free
$0
  • 1,000 calls a month
  • 30 calls a minute
  • Personal, research, journalism and prototypes
  • Credit “Data via Map the Block”
Developer
$19/mo
  • 50,000 calls a month
  • 120 calls a minute
  • Bulk downloads
  • Non-commercial and internal use
Pro
$79/mo
  • 500,000 calls a month
  • 300 calls a minute
  • Bulk downloads
  • Commercial use in your product
Business
$299/mo
  • 5,000,000 calls a month
  • 600 calls a minute
  • Commercial use, email support
  • Ask about custom layers

Billed monthly by Stripe. Cancel any time; your plan runs to the end of the paid month, then drops to Free. Questions: maptheblock@gmail.com.

Your keys

Checking your login…

Rules that come with the data

Full terms: Data API terms.

Home · The map · About the data · Terms · Privacy