Skip to main content

πŸš€ Quickstart

Connect to PostHog with Nango and see data flow in 2 minutes.
1

Create an integration

In Nango (free signup), go to Integrations -> Configure New Integration -> PostHog.
2

Authorize PostHog

Go to Connections -> Add Test Connection -> Authorize, then enter your Subdomain (e.g. us or eu.i) and API Key. Later, you’ll let your users do the same directly from your app.
3

Call the PostHog API

Let’s make your first request to the PostHog API (get current user). Replace the placeholders below with your secret key, integration ID, and connection ID:
curl "https://api.nango.dev/proxy/api/users/@me" \
  -H "Authorization: Bearer <NANGO-SECRET-KEY>" \
  -H "Provider-Config-Key: <INTEGRATION-ID>" \
  -H "Connection-Id: <CONNECTION-ID>"
Or fetch credentials dynamically via the Node SDK or API.βœ… You’re connected! Check the Logs tab in Nango to inspect requests.
4

Implement Nango in your app

Follow our Auth implementation guide to integrate Nango in your app.To obtain your own production credentials (subdomain and API key), follow the connect guide linked below.

πŸ“š PostHog Integration Guides

Nango-maintained guides for common use cases.
Subdomain: Use the part of your PostHog URL after https:// and before .posthog.com (e.g. us, eu.i for US/EU Cloud). PostHog enforces different rate limits per resource.
Official docs: PostHog API documentation

🧩 Pre-built syncs & actions for PostHog

Enable them in your dashboard. Extend and customize to fit your needs.

Others

Function nameDescriptionTypeSource code
actionsSync actions (saved event patterns) from PostHog.SyncπŸ”— Github
annotationsSync annotations from PostHogSyncπŸ”— Github
cohortsSync cohorts from PostHog.SyncπŸ”— Github
dashboardsSync dashboards from PostHog.SyncπŸ”— Github
early-access-featuresSync early access features from PostHog.SyncπŸ”— Github
event-definitionsSync event definitions (auto-detected event schemas) from PostHog.SyncπŸ”— Github
eventsSync events from PostHog.SyncπŸ”— Github
experimentsSync experiments from PostHog.SyncπŸ”— Github
feature-flagsSync feature flags from PostHog.SyncπŸ”— Github
insightsSync insights from PostHogSyncπŸ”— Github
personsSync persons from PostHogSyncπŸ”— Github
projectsSync projects from PostHog.SyncπŸ”— Github
session-recordingsSync session recording metadata from PostHogSyncπŸ”— Github
surveysSync surveys from PostHog.SyncπŸ”— Github