PostHog

Adds PostHog analytics, feature flags, session replay and error tracking to Payload

Community 1 8/wk MIT v0.2.0

Installation

pnpm add payload-posthog

About

PostHog connects Payload to the PostHog product analytics platform. Collection changes such as creating, updating and deleting documents are sent to PostHog as events, and you can rename those events or add your own properties. Logins to auth-enabled collections identify the user in PostHog, so events can be tied to a person.

The plugin also covers the rest of the PostHog toolset. Server-side helpers evaluate feature flags for access control, hooks and endpoints, and the admin panel gets a flags dashboard widget. Errors from Payload's error hook are reported to PostHog, and the admin panel can run session replay, surveys and autocapture. Ingestion can be routed through your own domain to reduce ad-blocker losses, and signed PostHog callbacks can be received as Payload webhooks. Every feature can be switched on or off separately.

Package info

Package name
payload-posthog
Latest version
0.2.0
Unpacked size
158 kB
License
MIT
Weekly downloads
8
Last publish
Jul 18, 2026

Similar plugins

More in Analytics

Creates and syncs Dub shortlinks for Payload documents as they are published

Sends Payload server errors and selected HTTP errors to Sentry with user context

Splits page traffic between variants you create in the Payload admin

Sales totals by period, product and customer for Payload ecommerce stores

Logs AI crawler visits, serves llms.txt and shows an AI visibility dashboard

Tracks AI API token spend and stops jobs when daily, monthly or per-job budgets run out