OAuth Field Guide
Live investigation · gemini-3.8-flash · 2026-10-28

Plausible Analytics

plausible.io · Web Analytics · for: Retrieve site traffic metrics, pageviews, and visitor stats to generate automated analytics reports or summaries.

⊘ No public OAuthNo public OAuthwhy this rating →
Do this next

OAuth 2.0 is not available for Plausible Analytics. Have users generate a Personal Access Token in Plausible settings (API Keys) on a Business plan, and collect this API key in your app interface.

Your path at a glance

Prepare
Register
Configure OAuth
Test
Launch
Agent
You
Milestones
◆ Works for you
5–15 min work
no wait
◆ Any customer
15–45 min work
no wait
agent can do you agent prepares, you finish assumedClick a step to jump to it.

Watch out for

Before you start

Steps

Register the app

  1. 2Generate Personal Access TokenYouopen ↗details →

Configure OAuth

  1. 3Configure HTTP Authorization headerAgent can dodetails →

Test with your account

  1. 4Execute test query against Stats APIAgent can doopen ↗details →

Launch to customers

  1. 5Implement rate limit and error handlingAgent can dodetails →

Copy & paste

Developer console
Not found in the provider's documentation
OAuth docs
https://plausible.io/docs/stats-api
Prompt for your coding agent
Show prompt
Create an API client for Plausible Analytics using Personal Access Token authentication. Store the API key securely, attach it via 'Authorization: Bearer <TOKEN>' headers on all requests, query stats endpoints using the site_id parameter, and handle rate limits (600 req/hr) and HTTP 401 errors.
.env.example
Show bash
PLAUSIBLE_API_KEY=your_personal_access_token_here
PLAUSIBLE_SITE_ID=example.com
plausibleClient.js
Show javascript
async function fetchPlausibleAggregateStats(siteId, apiKey) {
  const url = `https://plausible.io/api/v1/stats/aggregate?site_id=${encodeURIComponent(siteId)}&period=30d&metrics=pageviews,visitors,bounce_rate`;
  const response = await fetch(url, {
    headers: {
      'Authorization': `Bearer ${apiKey}`
    }
  });
  if (!response.ok) {
    throw new Error(`Plausible API error: ${response.status} ${response.statusText}`);
  }
  return await response.json();
}

Why & details

The reasoning, evidence and sources behind everything above. Hover a badge to see its sources.

The full picture

No public OAuth

Plausible Analytics does not offer OAuth 2.0 for third-party integrations, authenticating API access exclusively via Personal Access Tokens. Users must manually create an API key in their Plausible account settings and provide it to your application.

Plausible Analytics does not support standard OAuth 2.0 authorization flows for third-party applications. API authentication relies on static Personal Access Tokens passed as HTTP Bearer tokens.

Working with your own account
5–15 min hands-on · no wait

Developer or user creates a Personal Access Token in Plausible team settings.

Any customer can connect
15–45 min hands-on · no wait

Application backend securely prompts for, validates, and stores end-user Plausible API keys.

What affects your setup

Before you start — why each matters

How well this guide is backed

0 tested19 source-backed0 community-reported0 uncertain· Well evidenced (100% backed)

Step details

  1. Confirm that your Plausible account is on a Business plan or higher and obtain the domain name (site_id) configured in Plausible.

    👤 Why you: A product/business judgement only you can make

    🤖 What an agent can do: Document the site_id format and subscription prerequisite in UI microcopy.

    https://plausible.io/docs/stats-api ↗
  2. 2Generate Personal Access Token↑ back to step

    Log in to Plausible, navigate to account settings -> API Keys, click New API Key, select Stats API or Sites API, and save the token.

    👤 Why you: Needs your logged-in console session (2FA/CAPTCHA)

    🤖 What an agent can do: Provide direct step-by-step UI copy for users creating an API key inside Plausible.

    https://plausible.io/docs/api-keys ↗
  3. 3Configure HTTP Authorization header↑ back to step

    Store the token securely and send it with every request as an Authorization header ('Authorization: Bearer <TOKEN>').

    🤖 What an agent can do: Write HTTP client wrapper code that appends the Bearer token header to all Plausible API calls.

  4. 4Execute test query against Stats API↑ back to step

    Make a GET request to the aggregate endpoint with the site_id parameter to verify authentication and data retrieval.

    🤖 What an agent can do: Generate script to execute test API calls and parse site metric response payloads.

    https://plausible.io/docs/stats-api ↗
  5. 5Implement rate limit and error handling↑ back to step

    Handle 600 request/hour rate limits and 401 unauthorized errors gracefully in case the key is invalid or revoked.

    🤖 What an agent can do: Implement retry handling, backoff timers, and UI alerts prompting users to update their API key if invalidated.

Gotchas explained

Reference facts

What we verified — and what we couldn't

Live probes (no credentials)

  • ✓page https://plausible.io/docs/stats-apiHTTP 200; title "Plausible Stats API reference | Plausible docs"[P1]

Open questions

  • Is OAuth 2.0 planned on Plausible's product roadmap?
    Official documentation makes no mention of third-party OAuth 2.0 support or partner integration portals.
    To resolve: Contact Plausible support (https://plausible.io/contact) or monitor developer documentation updates.
  • Not searched: developer forums and community reports
    This key has no Google Search grounding, so only the provider's own pages were read. Real-world gotchas reported by developers may be missing.
    To resolve: Re-run with a billing-enabled Gemini key, or search the provider's community forum for review and rate-limit issues.

Ask the provider

A ready-to-send message built from the open questions above.

Send to
Plausible Support / Contact Form — https://plausible.io/contact
Subject
OAuth integration questions — Plausible Analytics
Hi Plausible Analytics developer support team,

We're building an integration where retrieve site traffic metrics, pageviews, and visitor stats to generate automated analytics reports or summaries. Before we register an OAuth app and launch to customers, we couldn't find answers to the following in your documentation:

1. Is OAuth 2.0 planned on Plausible's product roadmap?
   (What we found: Official documentation makes no mention of third-party OAuth 2.0 support or partner integration portals.)

Could you point us to the right documentation or process — including whether any review or approval is needed before customers outside our own account can connect, and the typical timeline?

Thanks,
[Your name]
[Company · website]

Sources