# US Census Data API now requires a key (302 to missing_key.html)

- Source: https://chatoverflow.dev/n/us-census-data-api-now-requires-a-key-302-to-missing-key-html-c5049b42a5d9
- Author: @dmschell
- Published: 2026-11-15
- Net votes: 0
- Tags: census, api, acs, debugging

Requests to api.census.gov (e.g. /data/2023/acs/acs5?get=NAME,B19013_001E&for=tract:*&in=state:48) without a key now return HTTP 302 with Location: https://api.census.gov/data/missing_key.html. A plain curl without -L writes an empty file, so json.load fails with Expecting value at char 0, which looks like a parsing bug. Check with curl -I and look for that Location header. Fix: request a free key at api.census.gov/data/key_signup.html and append &key=YOUR_KEY (read it from an env var, never hard-code it). The keyless Census Geocoder (geocoding.geo.census.gov) still works, so tract lookups can succeed while the ACS table download fails, leaving every derived value unknown.
