PostHog JS is a set of JavaScript and TypeScript packages for integrating PostHog into web and other applications. It is useful for sending usage data from your web app or site to PostHog, including autocapture, with supporting packages for frameworks like React and Next.js.
Project status
- PostHog/posthog-js appears actively maintained, with an upstream push recorded today (2026-09-10) and multiple dependency and
posthog-jspatch updates published within the same day. - The apparent update cadence is high, at least over the last 1-2 days, with several rapid
posthog-jspatch updates (e.g., 1.428.9 through 1.429.1) plus same-day updates to related packages (@posthog/types,@posthog/core, andposthog-react-native).
AI summary generated
Recent updates
posthog-js@1.429.1
posthog-js@1.429.1 is a patch release focused on session replay UI behavior, specifically preventing browsers from applying saved autofill suggestions inside replayed form fields. The code changes enforce `autocomplete="off"` for `input` and `textarea` elements both when rebuilding snapshots and when applying incremental mutations during replay.
posthog-js@1.429.0
posthog-js@1.429.0 adds Segment integration support for filtering PostHog enrichment properties before they are fanned out by Segment. It also includes multiple fixes around dead-click detection for text selection/editable caret gestures, TypeScript compatibility for replay events, and survey visibility behavior when capture is disabled.
Featuresposthog-react-native@4.68.4
posthog-react-native@4.68.4 is a patch release that is documented as a survey UI fix. However, the underlying monorepo diff also includes substantial, not-mentioned changes to replay JSON-LD capture and masking behavior, plus related type changes.
posthog-js@1.428.11
posthog-js@1.428.11 is a patch release focused on survey “open text” questions in the browser and React Native. It changes how the textarea placeholder is determined, removing the default “Start typing...” text when the configured placeholder is empty.
@posthog/types@1.409.4
This release adds replay URL privacy masking for URL-like string values inside captured JSON-LD payloads. The browser JSON-LD sanitizer now applies the privacy masking callback to additional cases, and normalizes inputs via trimming before masking.
posthog-js@1.428.10
posthog-js@1.428.10 applies replay URL privacy settings to URL-like values inside captured JSON-LD payloads, using a new shared URL-prefix detection helper. The release also bumps @posthog/types to 1.409.4 and @posthog/core to 1.52.0.
Features@posthog/types@1.409.3
This release adds the masked page URL to JSON-LD replay events. Concretely, JSON-LD custom events now carry an additional `href` field computed from the current page URL with the existing URL masking logic.
Featuresposthog-js@1.428.9
posthog-js@1.428.9 is a patch release focused on enriching JSON-LD replay data with the (masked) page URL. The implementation adds an `href` field to JSON-LD custom replay events and updates associated TypeScript types to expose that field.
Featuresposthog-react-native@4.68.3
posthog-react-native@4.68.3 is a patch release whose release notes only mention improved keyboard behavior when interacting with SurveyModal content. The code change for that behavior is present, and the only React Native source change is in SurveyModal touch handling. The diff also contains several repo-wide typing and build-system modifications (primarily rrweb declaration generation) that are not mentioned in the release notes.
@posthog/core@1.51.2
Release @posthog/core@1.51.2 is a patch update focused on packaging, specifically including the root license and attribution notices in the published @posthog/core package. The code diff also reveals several repo-wide changes around type generation and TypeScript annotations that are not described in the release notes.
@posthog/mcp@0.14.1
This patch release focuses on improving error-tracking behavior by collapsing repeated frame cycles in parsed stack traces, reducing grouping differences caused by recursion depth while still preserving distinct throw locations. It also updates underlying PostHog dependencies to newer versions.
posthog-node@5.51.8
posthog-node 5.51.8 is a patch release focused on improving error-tracking stack trace parsing. It collapses repeated frame cycles in parsed stack traces to reduce grouping differences caused by recursion depth, while keeping distinct throw locations.
posthog-js-lite@4.12.1
posthog-js-lite 4.12.1 is a patch release focused on error tracking stack trace parsing. It improves how parsed stack traces handle repeated frame cycles to reduce grouping differences caused by recursion depth, while keeping distinct throw locations intact.
posthog-js@1.428.8
posthog-js 1.428.8 includes a patch fix for error tracking, improving how parsed stack traces are grouped by collapsing repeated frame cycles. It also updates the bundled @posthog/core dependency to 1.51.1.
posthog-react-native@4.68.2
posthog-react-native@4.68.2 is a patch release that pulls in @posthog/core@1.51.1 and fixes how PostHog parses stack traces for error tracking. The main intended change is collapsing repeated recursion cycles in parsed stack traces to reduce grouping differences caused by recursion depth, while preserving distinct throw locations.
@posthog/core@1.51.1
Release 1.51.1 is a patch release for @posthog/core. The release notes document a fix to error-tracking stack trace parsing, collapsing repeated frame cycles in parsed stack traces to reduce grouping differences caused by recursion depth, while preserving distinct throw locations.
posthog-react-native@4.68.1
This patch release fixes Android native symbol uploads in a specific Expo Gradle mod interaction. If another Expo plugin registers an app Gradle mod before PostHog, symbol uploads should now work reliably.
@posthog/mcp@0.14.0
Release notes for @posthog/mcp@0.14.0 document a single minor change: capturing model identity from recognized client metadata before falling back to the injected llm_model argument. The actual code diff, however, shows multiple substantive behavioral changes across the browser runtime (transport selection during unload, retry queue behavior, request beacon fallback, Safari masked exception handling, and session recording buffer parking), none of which are mentioned in the release notes.
Featuresposthog-js@1.428.7
posthog-js@1.428.7 contains a patch aimed at fixing retry queue connectivity tracking after a page is restored from the back-forward cache (bfcache). The code updates PostHog page lifecycle handling and the retry queue to resume connectivity flushing on pageshow, while preventing reactivation after an explicit shutdown().
@posthog/types@1.409.2
This patch focuses on transport behavior for unbatched events during page unloading. It prefers `sendBeacon` for captures such as `{ send_instantly: true }` once PostHog's own unload handling marks the page as unloading, while keeping response-capable transports on active pages so failures can be retried, including when `fetch` is unavailable.