Positionstack

Operational

Accurate Address-to-Coordinate Conversion API · by APILayer

  • Geolocation
  • JSON · XML · GeoJSON
  • 2B+ addresses
  • 100ms avg response
Get your API key

Free plan · 100 requests / month · no card

Overview

API info

Positionstack is a free, real-time geocoding API that powers address validation and location services for developers and businesses worldwide. It delivers accurate forward and reverse geocoding for over 2 billion places and addresses in a lightweight JSON format.

Example request

GETShellcurl
curl --request GET \
  --url "https://api.apilayer.net/positionstack/v1/forward?access_key=YOUR_ACCESS_KEY&query=1600%20Pennsylvania%20Ave%20NW,%20Washington%20DC"
Run it in the Playground

Example response

200 - OK
{
    "data": {
        "results": [
            {
                "latitude": 40.763841,
                "longitude": -73.972972,
                "label": "Apple Store, Manhattan, New York, NY, USA",
                "name": "Apple Store",
                "type": "venue",
                "distance": 0,
                "number": "767",
                "street": "5th Avenue",
                "postal_code": "10153",
                "confidence": 1,
                "region": "New York",
                "region_code": "NY",
                "administrative_area": null,
                "neighbourhood": "Midtown East",
                "country": "United States",
                "country_code": "US",
                "map_url": "https://positionstack.com/download/map.html?bbox=-73.972472,40.764341,-73.973472,40.763341&marker=40.763841,-73.972972"
            }
        ]
    }
}

Features

  • Forward & reverse geocoding

    Effortlessly convert any global address into precise coordinates (forward geocoding) or transform latitude and longitude values into readable address data (reverse geocoding). This dual capability supports everything from map plotting to user location verification.

  • Real-time performance

    Process geocoding requests in real-time with response times ranging between 10 and 100 milliseconds. The API is built on a scalable cloud infrastructure capable of handling more than 1 billion daily lookup requests without compromising speed.

  • Extensive global coverage

    Access a massive dataset of over 2 billion addresses and places around the world, sourced from high-quality data vendors and updated multiple times per day. Positionstack covers accurate location data for every country, ensuring your application works globally.

  • Rich data embeddability

    Beyond simple coordinates, retrieve comprehensive location components including country, timezone, and sun module data. You can also instantly generate embeddable maps using the API’s returned map URLs.

Pricing

Flexible plan for every stage of growth

Start free. Upgrade when you go live.

MonthlyYearlySave up to 15%

Free

For testing and side projects

$0forever

No credit card

No overage charges

Get free API key

100 requests / month

Includes:

  • Forward Geocoding
  • Reverse Geocoding
  • HTTPS Encryption
  • Country Module

+ 4 more

See all 16 features

Starter

For your first live product

$9.99/ month

Billed monthly

Then $0.0003996 per extra request, up to 200,000 extra a month

Subscribe now

100,000 requests / month

Everything in Free, plus:

  • Commercial License
  • Extended Rate Limits
  • XML & GeoJSON Output
  • Embeddable Maps

+ 2 more

See all 16 features
Most popular

Professional

For growing traffic

$49.99/ month

Billed monthly

Then $0.00019996 per extra request, up to 2,000,000 extra a month

Subscribe now

1,000,000 requests / month

Everything in Starter, plus:

  • 10× the requests of Starter
  • Lower cost per request
  • Batch Requests
See all 16 features

Enterprise

For high volume

$99.99/ month

Billed monthly

Then $0.00013332 per extra request, up to 6,000,000 extra a month

Subscribe now

3,000,000 requests / month

Everything in Professional, plus:

  • 3× the requests of Professional
  • Lower cost per request
See all 16 features

Custom

Need more? Contact sales for custom needs.

Contact us

Compare all features

16 featuresFree$0Get free keyStarter$9.99/moSubscribeProfessional$49.99/moSubscribeEnterprise$99.99/moSubscribe
Forward Geocoding
Reverse Geocoding
HTTPS Encryption
Country Module
Sun Module
Timezone Module
Bounding Box Module
Specify Response Fields
Commercial License–
Extended Rate Limits–
XML & GeoJSON Output–
Embeddable Maps–
Multiple Languages Support–
Batch Requests––
Standard Support included–
Custom Solutions / Volume––––
Price per extra request after the monthly limitNone$0.0003996$0.00019996$0.00013332

Playground

Try the API

Build a request in your browser and see the response it returns.

GET
country_module Optional

Add your free API key to run it from your code.

curl
200 - OK

      
    

Agents

Agents: start here

Steps for AI coding agents that add Positionstack to a project.

  1. 1Get an API key

    A person creates the account: an agent cannot sign up. Sign up at app.apilayer.com and subscribe to Positionstack. The Free plan includes 100 requests / month and needs no credit card.

    Copy the API key from the APILayer dashboard and give it to the agent as an environment variable (step 2).

  2. 2Keep the key out of code

    Read the key from an environment variable named APILAYER_ACCESS_KEY. Do not write the key into source code, commit it to git, or paste it into a chat.

    Call Positionstack from server code. The key travels in the request URL, so a request sent from a browser shows the key to every visitor.

    .env
    # add .env to .gitignore
    APILAYER_ACCESS_KEY=your_api_key
  3. 3Make the first request

    Base URL
    https://api.apilayer.net/positionstack/v1
    Auth
    access_key query parameter
    Formats
    JSON, XML, GeoJSON
    Endpoints
    • /forward Forward geocoding
    • /reverse Reverse geocoding
    Shell
    curl "https://api.apilayer.net/positionstack/v1/forward?access_key=$APILAYER_ACCESS_KEY&query=1600%20Pennsylvania%20Ave%20NW,%20Washington%20DC"

    The API info tab shows the response this request returns.

  4. 4Check the plan before you use a feature

    Each plan adds features to the plan before it. Check that the account's plan includes a feature before writing code that uses it.

    PlanRequests / monthAdds
    Free100Forward Geocoding, Reverse Geocoding, HTTPS Encryption, Country Module, Sun Module, Timezone Module, Bounding Box Module, Specify Response Fields
    Starter100,000Commercial License, Extended Rate Limits, XML & GeoJSON Output, Embeddable Maps, Multiple Languages Support, Standard Support included
    Professional1,000,000Batch Requests
    Enterprise3,000,000Same features as Professional

    Prices are in the Pricing tab.

  5. 5Use the machine-readable docs

FAQs

Need clarity?

Here are the answers you might be seeking

Data & features

01.What is reverse geocoding in Positionstack API?

Reverse geocoding is the process of converting geographic coordinates (latitude and longitude) into a readable text address. It allows you to identify the specific location name, street, or city associated with a set of coordinates.

02.Who can use Positionstack API?

Positionstack is designed for everyone, from individual developers and startups to large enterprises. It scales to support thousands of web applications, mobile apps, and mapping services worldwide.

03.What is positionstack?

The API was built to offer an affordable and straightforward REST API interface for global forward and reverse geocoding in real-time, supporting nearly all countries worldwide with more than two billion global addresses covered. The API is making use of a number of trusted data sources to provide a high level of accuracy for every geocoding API request made. If you are interested in trying out the API, simply create a free account and be up and running within minutes.

04.How accurate is positionstack geocoding data?

Geocoding data returned by the positionstack API is sourced from multiple, highly reliable sources, such as Nominatim, GeoNames, Pelias and OpenStreetMap. Updates to our dataset are made multiple times per day and smart filters and algorithms ensure the highest possible level of consistency across API requests and accuracy in geo data responses.

05.What is the difference between forward and reverse geocoding?

Forward geocoding is the process of looking up a plain-text address or place name (e.g. Eiffel Tower), whereas reverse geocoding is performed by passing latitude and longitude values of a desired location to the API. If successful, both types of geocoding return an extensive array of location-related data as well as multiple potential results along with confidence scores.

06.Which countries are supported?

The positionstack API supports all countries worldwide. However, some countries come with better coverage than others, which is also the case for locations within a specific country. By combining and cross-checking multiple reputable geo data sources, our API does a great job at finding the exact location you are looking for, at any point.

API access

01.How do I make a forward geocoding request?

To make a forward geocoding request, send a request to the /forward endpoint with your access key and query. Example: http://api.positionstack.com/v1/forward?access_key=YOUR_ACCESS_KEY&query=Eiffel Tower.

02.How do I make a reverse geocoding request?

To make a reverse geocoding request, send a request to the /reverse endpoint using comma-separated coordinates. Example: http://api.positionstack.com/v1/reverse?access_key=YOUR_ACCESS_KEY&query=48.8584,2.2945.

03.Where can I find Positionstack API documentation?

APILayer has unified documentation for all products. You can find the full API documentation, including integration guides, code examples, and endpoint details, on our documentation page

04.What is an API Request?

One API request is consumed every time the positionstack API returns geocoding data, regardless of which endpoint was used for your request. If your request is unsuccessful and returns an error instead, your quota will not be affected.

05.What happens if I exceed my API Request volume?

Users will be automatically notified via e-mail and on their Account Dashboard once at least 75%, 90%, and 100% of their monthly API Request allowance has been reached. After reaching 100% of the allowance, overages fees will apply so we make sure you won’t experience any disruptions and your website/application will keep running smoothly.

06.What is the API's uptime?

Our API's system status is closely monitored around the clock. Every effort is made to ensure the highest possible level of availability and consistency, and we are proud to have an average uptime rate of nearly 100% (99.9%), calculated based on the past 12 months.

Plans & pricing

01.Is there a free geocoding API offered by Positionstack?

Yes, Positionstack offers a free geocoding API plan for personal use. It includes 100 free requests per month, forward geocoding, reverse geocoding, and HTTPS encryption, with no technical support included.

02.Can I also pay yearly?

Yes. If you choose annual billing, the total price of your subscription plan will be up to 15% lower than the total amount you would pay with a monthly payment frequency.

Overages

01.What is an overage?

An overage occurs when you go over a quota for your API plan. When you reach your API calls limit, we will charge you a small amount for each new API call so we can make sure there will be no disruption in the service we provide to you and your website or application can continue running smoothly.

Prices for additional API calls will vary based on your plan.

02.Why does APILayer have overage fees?

Overage fees allow customers to continue using an API once a quota limit is reached. We want to make sure your website or application continues running at all times, so charges will apply if you go over your monthly quota limit. If you notice you are going over your quota limit each month, look on your dashboard for an upgraded plan to help with larger request limits.

03.How do I know if I will be charged for overages?

When you are close to reaching your API calls limit for the month, you will receive an automatic notification (at 75%, 90%, and 100% of your monthly quota). You can keep track of your quota usage to prevent overages by tracking the number of API calls you make and checking the dashboard for up-to-date usage statistics.

04.What if I consistently have more API calls than my plan allows?

If your usage consistently surpasses the set limits each month, you may face additional charges for the excess usage. Nevertheless, as your monthly usage reaches a certain threshold, it becomes more practical to consider upgrading to the next plan. By doing so, you ensure a smoother and more accommodating experience for your growing customer base.

Still have a question?

Contact support