Skip to content

Run A/B tests on your site

Stop guessing what works. Test it with real users and let the data decide.

  1. 1
    PostHog

    Install posthog-js in your project with npm install posthog-js. Initialize it with your PostHog API key. In the PostHog dashboard, go to Experiments and create a new A/B test. Define your control and variant, set the rollout percentage, and add the feature flag check in your code to render the correct version for each user.

    Open PostHog
  2. 2
    Mixpanel

    Install the Mixpanel SDK and instrument the key conversion events you want to measure (for example, Signed Up, Upgraded, or Completed Checkout). In your Mixpanel Funnels report, segment by the PostHog feature flag property to compare conversion rates between your control and variant groups.

    Open Mixpanel
  3. 3
    Vercel

    For server-side variant assignment, use Vercel Edge Middleware to read the PostHog feature flag via the PostHog Node SDK before the page renders. This eliminates any flicker from client-side flag evaluation and ensures each user consistently sees the same variant across sessions and devices.

    Open Vercel

Estimated Monthly Cost

Verified Apr 2026
PostHog

1M events/mo, 5K recordings, unlimited feature flags

Free

Free

Vercel

Personal use only — 100 GB bandwidth, 1M edge req/mo

Free

Hobby

2 tools free at this scale
Est. total$0/mo

Estimates based on publicly listed pricing. Actual costs may vary — always verify on each tool's pricing page.

Frequently asked questions

Costs depend on your scale. Most tools in this stack offer a free tier to start. Open the cost calculator on this page to estimate monthly cost based on your users and revenue.

This stack uses 3 tools: PostHog, Mixpanel, Vercel. Each tool is picked to work well with the others and to cover a specific part of the workflow.

Yes. The stack is a recommended starting point. You can replace any tool with an alternative you already use. Check the setup guide first to confirm the integration points you'll need to rebuild.

Most makers finish the 3-step setup in under an hour. Creating accounts and connecting the first integration takes the most time.

Have a better stack?

Share your favorite tool combination and help other builders.

Suggest a stack