The best PostHog alternative is usually two or three tools, one for each PostHog product you actually use: Statsig as a single suite with unbilled flag checks, Amplitude for product analytics on signed-in users, GrowthBook for flags and experiments billed per seat, Sentry for errors, Microsoft Clarity for free session replay, and Plausible or invisit for the website. On PostHog’s own price list, a B2B team sending 4M events (3M of them from signed-in users), 20,000 recordings, 2M flag requests and 150,000 exceptions pays $572.30 a month, and $367.70 of that is two lines: identified events and flag requests.
The short answer by reason for leaving, as of November 2026:
- Most of your bill is identified events: Amplitude, which bills an event the same whether or not it belongs to a user, and imports your PostHog events.
- You want one suite like PostHog, with flag checks that are never billed: Statsig, now owned by Amplitude.
- You want flags and experiments billed per seat, or on your own servers: GrowthBook.
- You want deeper error tracking, with replays only when something breaks: Sentry.
- You want session replay and heatmaps for free: Microsoft Clarity.
- You only used PostHog for website analytics and want an EU company and the lightest script: Plausible.
- You want cookieless website analytics with funnels, heatmaps, web vitals and payment revenue: invisit, the tool we build.
The sections below price each piece at the same volume, list what you lose by splitting PostHog up, and end with how to leave without losing data.
Why do people look for PostHog alternatives?
People leave PostHog for four reasons: the bill grows on several meters at once, the team uses a fraction of the suite, the default script is heavy, or the self-hosted edition stops at hobby scale. Each product in PostHog has its own unit, free allowance and price, as listed on PostHog’s pricing page on November 3, 2026:
| PostHog product | Billed per | Free each month | First paid tier |
|---|---|---|---|
| Product analytics (web analytics included) | Event | 1M | $0.00005 an event |
| Identified events, for person profiles | Event | 1M | $0.000198 an event, on top |
| Session replay | Recording | 5,000 | $0.005 a recording |
| Feature flags and experiments | /flags request |
1M | $0.0001 a request |
| Error tracking | Exception | 100,000 | $0.00037 an exception |
| Surveys | Response | 1,500 | $0.10 a response |
| Data warehouse sources | Row | 1M | $0.000015 a row |
The list continues with destinations, batch exports, logs, AI observability, emails and AI credits. Prices fall with volume, and there are no seat charges. The limits that push teams away, from PostHog’s own pages:
- Several meters move together. A new signed-in user adds events, identified events, recordings and flag requests at once. PostHog says anonymous events “can be up to 4x cheaper than identified ones” (anonymous vs identified events).
- Flags bill by page load. posthog-js calls
/flagswhen it starts, when a user is identified and when person properties change, and a request is billed once it evaluates at least one active flag, even one your code never checks (cutting feature flag costs). One active flag makes every page load on your marketing site a billable request. - More suite than you use, in one script. A marketing site that only needs page views loads the same SDK as an app that uses flags: we measured
array.jsfrom posthog-js 1.445.1 at 118,651 bytes gzipped on November 3, 2026, and replay adds 68,469 bytes. By default posthog-js also sets aph_<project_token>_posthogcookie for 365 days (persistence). - Plan limits. The free plan has one project, and on paid plans every project in the organization shares one free allowance (billing FAQ). Events are kept 1 year free and 7 years paid; recordings up to 30 days free and 90 days on pay-as-you-go (recording retention).
- Self-hosting. The MIT hobby deploy wants a machine with 4 vCPU, 16 GB RAM and more than 30 GB of storage, has no tagged releases, and keeps every paid-plan feature on Cloud. PostHog’s disclaimer says it is “unlikely to scale past a couple 100ks events” without significant effort.
Who should stay on PostHog: a team inside the free allowances pays nothing, and no stack below beats free. That covers 1M events (about 500,000 page views at two events each), 5,000 recordings, 1M flag requests and 100,000 exceptions, with unlimited seats. Teams whose events are mostly anonymous also do well, at $324.40 for 10M events, and so do teams that open a replay from a funnel step or query every product with SQL every week. Startups under two years old with less than $5M raised can get $50,000 in credits for 12 months.
How much does PostHog cost for a typical team?
A B2B SaaS with a 500,000-page-view marketing site and a signed-in app pays PostHog $572.30 a month at the volumes below, using the tiers on PostHog’s pricing page on November 3, 2026.
The assumptions: each site page view sends two anonymous events, $pageview and $pageleave, the minimum with PostHog’s defaults (web analytics dashboard). The app sends 3M identified events, about what 35,000 monthly active users send at the 87 events per user PostHog measured for its own B2B product (estimating usage). One flag is active, so each of 2M page loads across site and app is a flag request.
| PostHog meter | Volume | Free each month | Monthly cost |
|---|---|---|---|
| Product analytics events | 4M (1M from the site, 3M from app) | 1M | $118.60 |
| Identified events add-on | 3M | 1M | $267.70 |
| Session replay | 20,000 recordings | 5,000 | $67.50 |
| Feature flag requests | 2M | 1M | $100.00 |
| Error tracking | 150,000 exceptions | 100,000 | $18.50 |
| Surveys | 1,000 responses | 1,500 | $0 |
| Total | $572.30 |
Two lines make up 64% of that bill: identified events ($267.70) and flag requests ($100). Anonymous events are cheap on PostHog. Moving only the marketing site to another tool removes 1M events and 500,000 flag requests and saves $84.30 a month, of which a $49 web analytics plan takes most.
What does the same team pay for a replacement stack?
Replacing PostHog piece by piece costs the same team $201.07 to $257.07 a month, a saving of $315.23 to $371.23. The saving comes from the identified events and flag request lines, and part of it goes back to errors, which cost more on Sentry. Both stacks below use each vendor’s published monthly price on November 3, 2026.
| Job | Stack A: one suite | Cost | Stack B: one tool per job | Cost |
|---|---|---|---|---|
| Website analytics, 500K page views | invisit Pro, 1M events | $49 | Plausible Starter, 500K page views | $49 |
| Product analytics, 3M app events | Statsig Pro, 5M metered events included | $150 | Amplitude Plus, 3M events | $94 |
| Feature flags and experiments | Statsig, flag checks unlimited | Included | GrowthBook Starter, up to 3 users | $0 |
| Session replay, 20,000 recordings | Statsig, 100,000 included | Included | Microsoft Clarity | $0 |
| Errors, 150,000 a month | Sentry Team, monthly billing | $58.07 | Sentry Team, monthly billing | $58.07 |
| Total | $257.07 | $201.07 |

invisit and Plausible cost the same at this volume, so either fits either stack. What the totals leave out:
- Statsig’s $150 holds while app events and experiment exposures stay under Pro’s 5M a month; each further million costs $50.
- GrowthBook Starter is free for three users and 1M CDN requests a month, then $10 per million. Five people on Pro cost $200, which takes stack B to $401.07.
- Errors cost more away from PostHog: $58.07 on Sentry Team against $18.50, because PostHog’s free allowance is 100,000 exceptions and Sentry Team includes 50,000.
- Sending the 20,000 recordings to Sentry instead of Clarity would cost $72.01, a little more than PostHog’s $67.50.
- You lose one event stream. In PostHog a funnel step opens its replays and an experiment reads the same events as your dashboards. Across tools you join them yourself, in a warehouse or by sending exposure events into your analytics tool.
What to look for in a PostHog alternative
Judge each replacement by the PostHog line it removes and the join it breaks. Six points separate the tools below:
- Which invoice lines are large. Your PostHog billing page shows usage per product; replace the expensive lines first and leave the free ones.
- Identified events. PostHog bills them up to 4x the anonymous rate; Amplitude and Statsig bill an event the same with or without a user.
- How flags are billed. Per
/flagsrequest (PostHog), per metered exposure with free flag checks (Statsig), per seat (GrowthBook), or unlimited flags with experiment results on a higher plan (Amplitude). - The joins you need. Replays from a funnel step, experiment results on product metrics, errors on a user profile: one suite keeps these together, separate tools need shared ids or a warehouse.
- Weight and consent, page by page. Your marketing site needs a small cookieless script; your app can carry heavier SDKs behind a login.
- History. Only Amplitude imports PostHog events; for every other tool, export before you cancel.
PostHog alternatives compared
The table compares the seven tools against PostHog on the criteria above; “Our example” is each tool’s share of the stacks priced in the previous section.
| Tool | Replaces in PostHog | Billed by | Free each month | Our example | Stored on the device by default | Imports PostHog history | Self-hosted |
|---|---|---|---|---|---|---|---|
| PostHog | Reference | Events, recordings, requests, exceptions | 1M events, 5,000 recordings | $572.30 | Cookie, 365 days | Not applicable | Hobby, unsupported |
| Statsig | Analytics, flags, experiments, replay | Metered events; flag checks free | 2M events, 50,000 replays | $150 | ID in localStorage | No | No |
| Amplitude | Product analytics, flags, replay | Events | 2M events, 10,000 replays | $94 | Cookie, 365 days | Yes, every plan | No |
| GrowthBook | Flags and experiments | Seats, plus CDN requests over quota | 3 users, 1M CDN requests | $0 to $200 | gbuuid cookie (script tag) |
No | Yes, MIT core |
| Sentry | Error tracking, replay | Errors, replays, spans | 5,000 errors, 1 user | $58.07 | Nothing; replay in sessionStorage | No | Yes, FSL |
| Microsoft Clarity | Replay, heatmaps | Free | No traffic limit | $0 | Cookie, 365 days | No | No |
| Plausible | Web analytics | Page views and events | None; 30-day trial | $49 | Nothing | Aggregated CSV only | Yes, AGPLv3 |
| invisit | Web analytics, heatmaps, web vitals | Page views and events | 20,000 events | $49 | Nothing | No | No |
Prices are monthly billing in each vendor’s own unit. GrowthBook’s range runs from Starter to five seats on Pro.
How much script does each replacement add?
Splitting PostHog lightens the marketing site most: a website analytics script of 2.5 to 8.5 KB replaces PostHog’s 119 KB. In the app, stack A loads about 95 KB and stack B about 147 KB, against about 194 KB for PostHog with replay and exception capture on.
We downloaded the script each vendor’s install docs point to on November 3, 2026 and compressed it with gzip -9, the method in our script size test, where the Plausible and Clarity figures come from.
| Script | What it covers | Bytes gzipped |
|---|---|---|
PostHog array.js (posthog-js 1.445.1) |
Analytics, flags, the SDK core | 118,651 |
PostHog lazy-recorder.js |
Session replay, when on | 68,469 |
PostHog exception-autocapture.js |
Error tracking, when on | 6,572 |
| Amplitude Browser SDK 2.48.1, the docs snippet | Analytics | 68,716 |
| Statsig js-client 3.33.7 with session replay and web analytics | Analytics, flags, experiments, replay | 62,689 |
Sentry bundle.min.js 11.10.0 |
Errors | 32,286 |
Sentry bundle.replay.min.js 11.10.0 |
Errors and replay | 73,817 |
Microsoft Clarity loader and clarity.js 0.8.75 |
Replay, heatmaps | 26,669 |
GrowthBook auto.min.js 2.0.0 |
Flags, experiments | 19,156 |
invisit.js |
Website analytics | 8,553 |
Plausible pa-*.js |
Website analytics | 2,485 |
PostHog fetches the replay and exception files only when those products are on, so a marketing page without replay loads array.js alone. The gain from splitting is that the site never downloads the app’s SDKs.
1. Statsig: best for one suite without per-request flag billing
Statsig is the closest thing to PostHog as a whole: product analytics, web analytics, feature flags, experiments and session replay on one event stream, with unlimited seats. Flag and config checks are unlimited on every plan, which removes PostHog’s request meter outright.
Statsig bills metered events. As of November 2026, Statsig’s pricing gives Developer 2M events, 50,000 replays and 1 year of analytics retention for free; Pro costs $150 a month for 5M events, then $0.05 per thousand, with 100,000 replays and unlimited retention. Replays are kept 30 days on both.
Metered events are your logged events plus exposures: a check that puts a user into an experiment, or into a partial rollout with Metric Lifts turned on, deduplicated per user for 60 minutes on client SDKs. Disabled flags and finished experiments are free. One catch from the same FAQ: each logged event carries one dimension, its value, for free, and Statsig charges an additional event for each additional dimension.
Statsig does better than PostHog on flags, on replay volume (50,000 free against 5,000) and on identified users, which cost nothing extra. Its SDK sets no cookies but keeps a stable ID in localStorage (stable ID), and EU rules treat storage on the device the same whatever the technology (what the law says).
Statsig does worse on continuity and history. OpenAI agreed to buy Statsig in September 2025, and Amplitude acquired the product, brand and customers on May 5, 2026 (Statsig’s note); Amplitude plans to connect the two at the data layer (phase 1). Warehouse imports are an Enterprise feature, there is no PostHog importer, and over Developer’s 2M events Metric Lifts stop until you pay $150.
Moving from PostHog: posthog.capture becomes client.logEvent, posthog.isFeatureEnabled becomes client.checkGate, and flags are recreated by hand. The docs’ script tag bundle measured 62.7 KB gzipped.
2. Amplitude: best for product analytics on signed-in users
Amplitude replaces PostHog’s product analytics for teams whose bill is mostly identified events: events tied to users, funnels, retention, cohorts and session replay, with unlimited seats and unlimited feature flags on every plan.
Amplitude bills events, with no surcharge for identified users. As of November 2026, Amplitude’s pricing has a Free plan of 2M events and 10,000 replays a month. Plus also starts free for 2M events, then costs $94 at 3M, $281 at 5M and $720 at 10M on monthly billing, read from the calculator data on that page. In our example the app’s 3M events cost $94, where PostHog charges $267.70 for the identified events add-on alone.
Amplitude does better than PostHog on identified events, on the free event allowance (2M against 1M), and on history: its Migrations panel imports PostHog event data on every plan, EU data center included, and migrated events count toward your monthly volume (self-service migrations).
Amplitude does worse on experiments and replay. Free and Plus run one active experiment without results; experiment results start on Growth, which has custom pricing. Replays stay at 10,000 a month on Free and Plus and are kept 1 month, data access is 1 year on Free and 2 on Plus against PostHog’s 7, and the analytics SDK alone measured 68.7 KB. The AMP_ cookie lasts 365 days by default (cookies and consent).
Moving from PostHog: run the Migrations panel first, then map posthog.capture to amplitude.track and posthog.identify to amplitude.setUserId. If Mixpanel is also on your list, our Mixpanel alternatives post prices Mixpanel, Amplitude and PostHog side by side from 2M to 20M events.
3. GrowthBook: best for feature flags and experiments billed per seat
GrowthBook replaces PostHog’s feature flags and experiments with a tool that charges for the people who manage flags, not for the users who see them. Its core is MIT-licensed and free to self-host with unlimited users (license).
As of November 2026, GrowthBook’s pricing offers Cloud Starter free for up to 3 users and 1 project, with unlimited flags, experiments and traffic, and 1M CDN requests a month. Pro costs $40 a seat a month for up to 30 users and 3 projects, with 2M CDN requests included and $10 per additional million.
A CDN request is a download of your flag definitions, not an evaluation. The JavaScript SDK evaluates flags in the browser from a payload it caches in localStorage and treats as fresh for 60 seconds by default (JavaScript SDK), so repeat page loads within that minute fetch nothing. Past the included requests, a million more costs $10, where PostHog charges $100 for its second million.
GrowthBook does better than PostHog on flag cost at volume and on self-hosting, and the seat price does not move with traffic. Pro adds sequential testing, CUPED, sticky bucketing and multi-armed bandits.
GrowthBook does worse on the join. Experiment results are computed from a data warehouse you connect, or from GrowthBook’s managed warehouse (1M events a month on Starter, 2M on Pro, then $0.03 per thousand). GrowthBook documents no PostHog integration, so you send exposures to your analytics tool through trackingCallback and export that tool’s data to a warehouse, as its Amplitude guide describes. The script tag sets a long-lived gbuuid cookie (script tag) and measured 19.2 KB.
Moving from PostHog: recreate each flag with the same key, then swap posthog.isFeatureEnabled('key') for gb.isOn('key') and posthog.getFeatureFlag('key') for gb.getFeatureValue('key', fallback).
4. Sentry: best for error tracking, with replays when something breaks
Sentry replaces PostHog’s error tracking with a dedicated tool: stack traces with source maps, tracing, logs, uptime and cron monitors, and session replays it can record only for sessions that hit an error.
Sentry bills errors, replays and spans. As of November 2026, Sentry’s pricing has a free Developer plan for one user with 5,000 errors. Team costs $26 a month billed yearly or $29 monthly, for unlimited users, 50,000 errors and 50 replays. Extra errors on Team cost $0.0003625 each up to 100,000 and $0.0002188 up to 500,000 (pricing details), so 150,000 errors cost $58.07 a month.
Sentry does better than PostHog on depth and privacy defaults. replaysOnErrorSampleRate buffers the last minute and keeps a replay only when an error happens, and the SDK sets no cookies; replay uses sessionStorage for the open tab (Sentry’s replay FAQ). You choose US storage in Iowa or EU storage in Frankfurt (data storage location), and the self-hosted edition is free under the FSL.
Sentry does worse on price at this volume: $58.07 against PostHog’s $18.50 for the same 150,000 exceptions, because PostHog’s free allowance is twice Sentry Team’s included errors. Its replays are not tied to your product analytics funnels, and its error-only bundle measured 32.3 KB, 73.8 KB with replay.
Moving from PostHog: posthog.captureException(error) becomes Sentry.captureException(error), and you upload source maps to Sentry. Existing issues stay in PostHog.
5. Microsoft Clarity: best for free session replay and heatmaps
Microsoft Clarity records sessions and builds click, scroll and attention heatmaps for free, with no traffic limit and no paid plan (Clarity FAQ). It replaces PostHog’s replay meter, which charged $67.50 for 20,000 recordings in our example.
Clarity keeps up to 100,000 recordings per project per day and samples above that. Recordings are kept 30 days, then 1% of them, or 10 a day, for up to 9 months (data retention). Its script, loader included, measured 26.7 KB, the smallest session recorder in our tests.
Clarity does better than PostHog on price and on free volume: PostHog’s free tier is 5,000 recordings a month.
Clarity does worse on context, consent and data use. PostHog’s replays show console logs and network requests and sit one click from your funnels and errors; Clarity’s sit in Microsoft’s dashboard. Clarity sets _clck for 365 days plus Microsoft cookies, and since October 31, 2025 it enforces consent signals for visitors from the EEA, the UK and Switzerland, so without consent each page view becomes its own session (consent mode). Clarity’s terms let Microsoft use the data to create user profiles for advertising and rule out sites aimed at under-18s and health, financial or government content. Our free web analytics post covers those terms.
Moving from PostHog: add the Clarity tag and turn off PostHog replay. Recordings do not transfer; export the ones you need to JSON one at a time before they expire.
6. Plausible: best for website analytics alone, from an EU company
If PostHog was mostly measuring your marketing site, Plausible replaces it with one page of cookieless traffic stats, data in Germany, and a company whose providers are all European.
Plausible bills page views plus custom events. As of November 2026, Plausible’s pricing at 500,000 is $49 on Starter, $74 on Growth and $99 on Business, the plan with funnels, custom properties, revenue goals and the Stats API. There is no hosted free plan; the trial is 30 days. Community Edition is free under AGPLv3, without funnels.
Plausible does better than PostHog on the site: no cookie to put behind a banner, a 2.5 KB script against 119 KB, Search Console queries, a Google Analytics 4 importer and scheduled email reports.
Plausible does worse on anything past the website. There are no users, cohorts, replays or flags, no view of a single visit, and funnels only on Business. History from PostHog has to be summed into Plausible’s aggregated CSV import format; events and persons do not carry over.
Moving from PostHog: posthog.capture('signup', { plan: 'pro' }) becomes plausible('Signup', { props: { plan: 'pro' } }), and page views need no call. See Plausible vs invisit.
7. invisit: best for cookieless website analytics with funnels, heatmaps and revenue
invisit, the tool we build, replaces PostHog’s web analytics, heatmaps and web vitals for the website, next to whatever you keep for the product. It sets no cookies and stores nothing on the device; visitors are told apart with a hash whose salt changes every day and is then deleted.
invisit bills page views, custom events (including automatic outbound-link and download events), conversions and short-link clicks. Bots, crawler reads, web vitals, engagement, heatmap clicks and identify calls are never billed. The Free plan covers 20,000 events a month on 4 sites without a card, and paid plans cost $14 for 100K, $49 for 1M and $99 for 3M (pricing). Data is kept forever.
invisit does better than PostHog on the website. The script is about 8.5 KB against 119 KB, heatmaps show clicks, rage clicks, dead clicks and scroll depth per element on your live pages, and web vitals never count toward the bill, where PostHog bills each $web_vitals event. Referrals from 19 AI assistants, crawler reads recorded server-side, and revenue from Stripe, Paddle, Polar, Lemon Squeezy, Creem or Dodo Payments sit beside your traffic.
invisit does worse on everything else PostHog does. There are no session recordings, feature flags, experiments, retention cohorts, error tracking, surveys, mobile SDKs or self-hosting. Funnels have 2 to 8 steps within one visit, identify(user.id) attaches only a hash of your id, revenue is not attributed to sources, and invisit cannot import history.
Moving from PostHog: posthog.capture('signup', { plan: 'pro' }) becomes track('signup', { plan: 'pro' }), with up to 32 properties (events guide). See PostHog vs invisit for cookies, EU hosting and price per page view.
Can you self-host a PostHog replacement?
Partly. GrowthBook, Sentry and Plausible Community Edition run on your own servers; Statsig, Amplitude, Clarity and invisit are hosted only. Self-hosting does not shrink the hardware: Sentry alone asks for the same 16 GB of RAM as PostHog’s hobby deploy.
| Self-hosted edition | License | What it leaves out |
|---|---|---|
| PostHog hobby deploy | MIT | Every paid-plan feature, support, and scale past a couple hundred thousand events |
| GrowthBook Open Source | MIT, except enterprise directories | SSO, approval workflows, bandits, sticky bucketing and holdouts |
| Sentry self-hosted | FSL, Apache 2.0 after two years | Spike protection, Seer AI, some mobile symbolication |
| Plausible Community Edition | AGPLv3 | Funnels, user journeys, revenue goals, SSO |
PostHog’s hobby deploy wants 4 vCPU, 16 GB RAM and more than 30 GB of disk. Sentry’s self-hosted docs ask for at least 4 CPU cores, 16 GB RAM plus 16 GB swap (32 GB recommended) and 20 GB of disk, and do not list replay among what self-hosted lacks, so Sentry is the one pick here that also records sessions on your servers. GrowthBook’s limits come from its pricing page and Plausible’s from our comparison.
When should you stay on PostHog?
Stay on PostHog when its free allowances cover you or when the joins between its products are the reason you use it. PostHog is the better choice in these cases:
- You fit the free tiers: 1M events, 5,000 recordings, 1M flag requests, 100,000 exceptions and 1,500 survey responses a month, with unlimited seats.
- Your events are mostly anonymous. 10M of them cost $324.40, less than Amplitude Plus at the same volume.
- You open replays from funnel steps, read experiments on the same events as your dashboards, and query everything with SQL.
- Errors are your largest volume. PostHog includes 100,000 exceptions free; Sentry Team includes 50,000 for $29.
- You qualify for the startup program: $50,000 in credits for 12 months.
If one line dominates your invoice, replace that line first and price the rest again. In our example the identified events add-on alone is 47% of the bill.
How do you switch from PostHog without losing data?
Export your PostHog data first, replace one product at a time starting with the largest invoice line, and run old and new side by side for two to four weeks before you remove posthog-js.
- Export events. Batch exports send events, persons and sessions to S3, BigQuery, Snowflake, Postgres, Redshift, Databricks or Azure Blob Storage, with a backfill for past data; the first 1M rows a month are free, then $0.000015 a row up to 10M. File download exports return Parquet or JSON Lines through the API.
- Import where you can. Amplitude’s Migrations panel reads PostHog directly; for every other tool, the export is your archive.
- Save the recordings you need as JSON, one at a time, before PostHog’s retention deletes them.
- Recreate flags with the same keys in the new tool, and keep PostHog flags on until every client, including mobile app versions still in use, reads the new ones.
- Move the marketing site first: install a website analytics script there and remove posthog-js, or set
advanced_disable_feature_flagson those pages. - Map your calls in the app, with each new SDK running next to PostHog:
import * as amplitude from '@amplitude/analytics-browser'
import { GrowthBook } from '@growthbook/growthbook'
import * as Sentry from '@sentry/browser'
amplitude.init('<AMPLITUDE_API_KEY>')
Sentry.init({
dsn: '<SENTRY_DSN>',
integrations: [Sentry.replayIntegration()],
replaysSessionSampleRate: 0, // no replays for healthy sessions
replaysOnErrorSampleRate: 1.0, // keep a replay whenever an error happens
})
export const gb = new GrowthBook({
apiHost: 'https://cdn.growthbook.io',
clientKey: '<GROWTHBOOK_CLIENT_KEY>',
// Send exposures to Amplitude so experiment results can use the same events
trackingCallback: (experiment, result) => {
amplitude.track('Experiment Viewed', { experimentId: experiment.key, variantId: result.key })
},
})
await gb.init()
export function signedIn(userId: string) {
amplitude.setUserId(userId) // was posthog.identify(userId)
gb.setAttributes({ id: userId })
Sentry.setUser({ id: userId })
}
amplitude.track('signup', { plan: 'pro' }) // was posthog.capture('signup', { plan: 'pro' })
const newCheckout = gb.isOn('new-checkout') // was posthog.isFeatureEnabled('new-checkout')- Compare for two to four weeks. Visitor counts will differ: PostHog’s and Amplitude’s cookies recognise a visitor for a year, a daily hash such as Plausible’s or invisit’s for a day.
- Remove posthog-js, then review your consent banner against what the remaining tools store on the device (cookie banners for analytics).
Before you remove posthog-js
- Batch export or file export of events, persons and sessions finished and spot-checked.
- PostHog events imported into Amplitude, if Amplitude is your product analytics pick.
- Recordings you need saved as JSON.
- Every flag recreated with the same key, and old app versions accounted for.
-
capture,identify,isFeatureEnabledandcaptureExceptioncalls mapped. - Funnels, dashboards and alerts rebuilt, or knowingly dropped.
- Both setups compared for two to four weeks.
- Consent banner reviewed against what the new tools store on the device.
