# Access the API

The Google API works on top of the SERP API, which is available via GET requests sent to our official API endpoint and by specifying the `engine=<GOOGLE_ENGINE>` query parameter.

The official SERP API endpoint is:

* `https://serpapi.webscrapingapi.com/v2`

To choose the appropriate `engine` check out the available [Google Search Engines](https://docs.webscrapingapi.com/google-search-api/google-search-engines).

{% hint style="info" %}
You can use this as the base URL for the Google API: **`https://serpapi.webscrapingapi.com/v2?api_key=<YOUR_API_KEY>&engine=<GOOGLE_ENGINE>`**
{% endhint %}

### The API key

Our SERP API requires an API key for authentication. The key is embedded in the URL as a query parameter called `api_key` and has to be included on each GET request, for the request to pass. Failing to pass the <mark style="color:yellow;">**required**</mark> `api_key` parameter or passing an incorrect key will result in an `Unauthorized` HTTP status.

To obtain an API key for the SERP API, you have to:&#x20;

1. [Register](https://docs.webscrapingapi.com/readme/registration) a new account on our official platform
2. Subscribe to the SERP API service from within the Dashboard

{% hint style="success" %}
Subscription to the SERP API gives you access to all supported engines: Google, Bing and Yandex.
{% endhint %}

In the following documentation, we will refer to the API key by using this syntax:**`<YOUR_API_KEY>`**

{% hint style="warning" %}
Please make sure to store your private API key in a secure location and never make it publicly available. Using the API key directly impacts you subscription plan. &#x20;
{% endhint %}
