Browse help articles
Support homeShare and export

API

Use the API to manage sites, events and milestones, or pull custom reports. Once you have a key, see the API reference.

Create an API key

  1. Go to Settings, then API.
  2. Click Add new.
  3. Give the key a name, so you know later what uses it (for example, “Zapier”).
  4. Choose its access:
    • Full access: an admin key. It can do everything the API allows, including adding and deleting sites.
    • Read all sites: read stats for every site, including sites you add later.
    • Read some sites: read stats for up to 1,000 sites you pick.
    • Manage some sites: read stats, and change and delete events, for up to 1,000 sites you pick. It can’t delete a site.
  5. For Read some sites or Manage some sites, tick the sites. Each site shows its Site ID.
  6. Click Create key.
  7. Copy the key, tick the box to confirm you’ve saved it, and click Close. We only show a key once.
The Create API key form, with the name Weekly reporting script, Read some sites selected, and acme.com and docs.acme.com ticked in the site list with their Site IDs

To change a key’s name, access or sites later, click Edit next to it on the API page.

Disable or delete a key

Click Disable next to a key to stop it working straight away. A disabled key keeps its secret, so you can click Enable to turn it back on. To delete a key for good, disable it first, then click Delete.

Each key shows who created it and when it was last used. If a disabled key is still being called, the API page tells you, so you can find what still uses it before you delete it.

API keys on a team

On the Business plan, team admins can create and manage API keys too. A key an admin creates belongs to the team, not to them: it only reaches the team’s sites, and it keeps working if they leave. Editors and viewers on a team can’t open its API page.

Find help with setup, your analytics, or your account.