This API returns the Walk Score for any location.
Live Walk Score API call.
Programmers can use the API to:
- Integrate Walk Score into your site
- Add Walk Score to your property listings
- Enable searching and sorting by Walk Score
The Walk Score API is supported in the United States, Canada, Australia, and New Zealand.
API Examples
Show the Walk Score and Transit Score of millions of properties every day.
Allow your visitors to search and sort apartments by Walk Score.
Getting Started
To start using the API, request an API key.
Branding Requirements
All API calls must comply with the Walk Score branding requirements.
For example integrations of the Walk Score API, see our case studies.
Sample Code
Calls to the Walk Score API must be made from a server-side script. View sample code.
Walk Score API Calls
There are two available API calls from the base URL http://api.walkscore.com:
| Name | URL | Description |
|---|---|---|
| score | / | Returns the Walk Score for a given location. |
| walking distance | /walk_shed/ | Returns walking distance polygon for a given location. |
The "Walk Score" API Call
EXAMPLE. To get the Walk Score for 1119 208th Ave S, Seattle, WA, make the following call:
http://api.walkscore.com/score?format=xml&
address=1119%208th%20Avenue%20Seattle%20WA%2098101&lat=47.6085&
lon=-122.3295&wsapikey=<YOUR-WSAPIKEY> The Walk Score API will return the following:
<result>
<status>1</status>
<walkscore>95</walkscore>
<description>walker's paradise</description>
<updated>2009-12-25 03:40:16.006257</updated>
<logo_url>http://www2.walkscore.com/images/api-logo.gif</logo_url>>
<more_info_icon>http://www2.walkscore.com/images/api-more-info.gif</more_info_icon>
<ws_link>http://www.walkscore.com/score/1119-8th-Avenue-Seattle-WA-98101/lat=47.6085/lng=-122.3295/?utm_source=myrealtysite.com&utm_medium=ws_api&utm_campaign=ws_api</ws_link>
<snapped_lat>47.6085</snapped_lat>
<snapped_lon>-122.3295</snapped_lon>
</result> The Walk Score API takes the following parameters:
| Parameter | Description | Required |
|---|---|---|
| lat | The latitude of the requested location. | Yes |
| lon | The longitude of the requested location. | Yes |
| address | The URL encoded address. | Yes |
| wsapikey | Your Walk Score API Key. Contact us to get one. | Yes |
| format | Return results in XML or JSON (defaults to XML). | No |
The Walk Score API returns an XML or JSON response containing:
| Result | Description |
|---|---|
| status | Status code of the result (see information below). |
| walkscore | The Walk Score of the location. |
| description | An English description of the Walk Score. E.G. Somewhat Walkable. |
| updated | When the Walk Score was calculated. |
| logo_url | Link to the Walk Score logo. |
| more_info_icon | Link to question mark icon to display next to the score. |
| more_info_link | URL for the question mark to link to. |
| ws_link | A link to the walkscore.com score and map for the point. |
| snapped_lat | All points are "snapped" to a grid (roughly 500 feet wide per grid cell). This value is the snapped latitude for the point. |
| snapped_lon | The snapped longitude for the point. |
Handling Unavailable Walk Scores
If a Walk Score is unavailable via the Walk Score API, show the text "Get Score" with a link to the property on Walk Score (ws_link).
If the request to the API fails entirely (network timeout, error response, etc.), this option can be used with a link to the Walk Score homepage instead (www.walkscore.com).
All of these requirements are implemented in our sample code.
Walk Score API Status and Error Codes
Successful API requests return an HTTP 200 response with the following status codes:
| HTTP Response | Status Code | Description |
|---|---|---|
| 200 | 1 | Walk Score successfully returned. |
| 200 | 2 | Score is being calculated and is not currently available. |
| 404 | 30 | Invalid latitude/longitude. |
| 500 series | 31 | Walk Score API internal error. |
| 200 | 40 | Your WSAPIKEY is invalid. |
| 200 | 41 | Your daily API quota has been exceeded. |
| 403 | 42 | Your IP address has been blocked. |
Contact us for tech support.
The "Walking Distance" API Call
a.k.a. Walkshed API Call
EXAMPLE. To get the walking distance polygon for 47.5815, -122.335, make the following call:
http://api.walkscore.com/walk_shed?lat=47.5815&lon=-122.335&wsapikey=<YOUR-WSAPIKEY> The Walking Distance API will return the following JSON:
{
"status": 1,
"walk_shed":
{
"origin":
{
"lat": 47.58151,
"lon": -122.33515
},
"geometry":
{
"type": "Polygon",
"coordinates": [[
[-122.32469, 47.58189],
[-122.33325, 47.58187],
[-122.32799, 47.58401],
[-122.32596, 47.58616],
[-122.32905, 47.58824],
[-122.32999, 47.58823],
[-122.33232, 47.59028],
[-122.33423, 47.59029],
[-122.33746, 47.59037],
[-122.33654, 47.58401],
[-122.3367, 47.58181],
[-122.34001, 47.57713],
[-122.33985, 47.57437],
[-122.33669, 47.57171],
[-122.33418, 47.57142],
[-122.33145, 47.57333],
[-122.32999, 47.57436],
[-122.32907, 47.57551],
[-122.32799, 47.57772],
[-122.32522, 47.57773],
[-122.32347, 47.57982],
[-122.32599, 47.58118],
[-122.32469, 47.58189]
]]
},
"radius": 0.75
},
"snapped_lat": 47.5815,
"snapped_lon": -122.335
}
The Walking Distance API takes the following parameters:
| Parameter | Description | Required |
|---|---|---|
| lat | The latitude of the requested location. | Yes |
| lon | The longitude of the requested location. | Yes |
| wsapikey | Your Walk Score API Key. Contact us to get one. | Yes |
The Walking Distance API returns a JSON response containing:
| Key | Description |
|---|---|
| walk_shed | a GeoJSON object (http://geojson.org/) and returns points as [lon, lat] tuples. |
| radius | In miles. |
| origin | Where we've located the point on the road network. |
| snapped_lat | the canonical snapped location latitude (to 0.0015 degrees). |
| snapped_lon | the canonical snapped location longitude (to 0.0015 degrees). |
Walking Distance API Status and Error Codes
Successful API requests return an HTTP 200 response with the following status codes:
| HTTP Response | Status Code | Description |
|---|---|---|
| 200 | 1 | Walk shed successfully returned. |
| 200 | 2 | Walk shed unavailable. |
| 404 | 30 | Invalid latitude/longitude. |
| 500 series | Walk Score API internal error. | |
| 200 | 40 | Your WSAPIKEY is invalid. |
| 200 | 41 | Your daily API quota has been exceeded. |
Contact us for tech support.
