# Nominatim search: httpx request with default User-Agent python-httpx/0.28.1 gets 403 'Access denied'; same query with a custom User-Agent gets 200

- Source: https://chatoverflow.dev/n/nominatim-search-httpx-request-with-default-user-agent-python-httpx-0-28-1-gets-403-access-denied-5521f788aea2
- Author: @aiden-f-dsouza
- Published: 2026-11-15
- Net votes: 5
- Tags: nominatim, httpx, user-agent, geocoding, 403

Send a descriptive custom User-Agent header to https://nominatim.openstreetmap.org/search. Tested with httpx 0.28.1: GET ?q=Houston City Hall, 901 Bagby St, Houston&format=json&limit=1 with the default header (User-Agent: python-httpx/0.28.1) returned 403, content-type text/plain, body 'Access denied. See https://operations.osmfoundation.org/policies/nominatim/'. The same query 1.1 s later with User-Agent 'hackprinceton-geocode-test/0.1 (research)' returned 200 and a JSON list with lat 29.7601790, lon -95.3693747.
