• Product
  • Pricing
  • Docs
  • Using PostHog
  • Community
  • Company
  • Login
  • Home
  • CEO diaries
    • After the HN launch
    • Remote companies can be too asynchronous
    • The time before YC
    • Winning from the back - late mover advantage
    • Optimize for not breaking up with your co-founder
    • Cancer and revenue - the latest board meeting
    • "How come your website is so nice?"
    • Things I learned last year
    • Our new objective: Nail Self Serve
    • How we found our Ideal Customer Profile
    • Tell me about features, not benefits
    • The magic of a Hacker News Pre-Mortem
    • How to run a transparent startup
    • How we justified quitting our jobs and financing PostHog early on
    • How we made something people want
    • Moving to San Francisco
    • Pivot to PostHog
    • Counterintuitive lessons about our pricing
    • I used to think you don't need product people. I was wrong.
    • How we raised $3M for an open source project
    • A story about pivots
    • The YC Interview
    • Raising money is less stressful than bootstrapping
    • What motivates me as a CEO
    • The really important job interview questions engineers should ask (but don't)
    • Writing for developers
    • Reflecting on YC, 2 years on
  • Company & culture
    • How we do meetings at PostHog
  • Comparisons
    • PostHog vs Matomo
    • PostHog vs Amplitude
    • Why I ditched Google Analytics and Mixpanel for PostHog
  • Engineering
    • Enabling zero downtime data migrations for self-hosted users
    • Automating a software company with GitHub Actions
    • How to speed up ClickHouse queries using materialized columns
    • In-depth: ClickHouse vs PostgreSQL
    • Setting up super fast Cypress tests on GitHub Actions
    • How I learned to love feedback loops (and make better products)
    • Frontend filters & backend SQL - A chat with Eric Duong, Sam Winslow, James Greenhill, and Buddy Williams
    • PostHog Joins Hacktoberfest 2020
    • How PostHog built an app server (from MVP to billions of events)
    • How we’re making PostHog deployments easier
    • Solving the mystery of PostHog’s missing session recordings
    • I used to think you don't need product people. I was wrong.
    • The secrets of PostHog query performance
    • Benchmarking the impact of session recording on performance
    • The state of plugins on PostHog
    • We ship whenever
  • General
    • Setting up super fast Cypress tests on GitHub Actions
    • How we designed the PostHog mascot
    • Why you may not need a sales team
    • A story about pivots
  • Guides
    • Introduction to self-service analytics
    • Building an AARRR pirate funnel (how and why)
    • 5 essential tips for Customer Success teams on PostHog
    • 5 analytics ideas for marketing teams using PostHog
    • Automating a software company with GitHub Actions
    • The most useful B2B SaaS product metrics
    • The 7 best GDPR-compliant analytics tools
    • The best HIPAA-compliant A/B testing tools
    • The 5 best free and open-source A/B testing tools
    • The 4 best HIPAA-compliant analytics tools
    • The best open-source analytics and data tools
    • Open source (and self-hosted) alternatives to Hotjar & FullStory
    • The two ways to estimate your monthly event usage
    • How to speed up ClickHouse queries using materialized columns
    • In-depth: ClickHouse vs PostgreSQL
    • Google is about to make it a lot harder to track website and app users without third-party cookies
    • Setting up super fast Cypress tests on GitHub Actions
    • 5 essential PostHog apps for new users
    • 5 events all teams should track with PostHog
    • What launching Experimentation taught us about running effective A/B tests
    • How to get the first 10 paying customers for your devtool company (and other customer acquisition tips)
    • The best GA4 alternatives for apps and websites
    • How to harness the awesome power of growth loops
    • What is user segmentation?
    • How to measure product engagement
    • How to achieve B2B product market fit
    • How to work out what your users really need
    • How we do hiring & HR at PostHog
    • How we turned ClickHouse into our event mansion
    • An introduction to customer retention
    • Is Google Analytics HIPAA compliant?
    • Finding your North Star metric and why it matters
    • How we monetized our open source devtool
    • Building an open source data stack
    • How to plan a killer company offsite in just 8 weeks
    • Permissions and projects in PostHog, explained
    • How (and why) our marketing team uses PostHog
    • PostHog vs Matomo
    • PostHog vs Amplitude
    • Product engineer vs software engineer: what's the difference?
    • Don’t bother securing your trademarks in the beginning
    • How to seed, grow, and scale Developer Relations (and how we're doing it at PostHog)
    • The ops toolkit for early-stage startups
    • How (and why) to track your website with PostHog
    • 22 ways PostHog makes it easier to build great products
    • What is a product engineer (and why they're awesome)
    • A simple guide to personal data and PII
    • An introduction to product analytics and how it works
    • What is SSO and why you should enable it for PostHog
    • The 3 critical reasons companies choose self-hosted analytics
  • HogMail
    • HogMail #14
    • HogMail #15
    • HogMail #16
    • HogMail #17: The personal traits that can't be taught
    • HogMail #18: What can SaaS learn from the New York Times?
  • Inside PostHog
    • PostHog raises $15 million Series B for open source product analytics
    • A non-coders thoughts on ‘Everybody Codes’ - Part Two
    • A non-coder's thoughts on an 'Everybody Codes' culture
    • After the HN launch
    • Remote companies can be too asynchronous
    • The time before YC
    • How PostHog uses Wren to offset carbon emissions during offsites
    • Winning from the back - late mover advantage
    • Optimize for not breaking up with your co-founder
    • Cancer and revenue - the latest board meeting
    • "How come your website is so nice?"
    • Things I learned last year
    • Our new objective: Nail Self Serve
    • How we found our Ideal Customer Profile
    • How we do customer support at our open source devtool company
    • The importance of dogfooding - Why product managers should use their product as much as their users
    • How we designed the PostHog mascot
    • Using Gatsby and Puppeteer to create dynamic Open Graph images
    • Creating an employee-friendly startup share option scheme
    • Tell me about features, not benefits
    • How I learned to love feedback loops (and make better products)
    • The magic of a Hacker News Pre-Mortem
    • HostHogs - free drinks, free pizza and frequently asked questions
    • How to run a transparent startup
    • How we do hiring & HR at PostHog
    • How PostHog built an app server (from MVP to billions of events)
    • How we turned ClickHouse into our event mansion
    • How we justified quitting our jobs and financing PostHog early on
    • Introducing Phil Leggetter, our new head of Developer Relations
    • Using Google Analytics was deemed 'illegal' in some EU countries. We built a microsite in 48 hours to capitalize on the news.
    • Introducing Joe Martin - Our first Product Marketer
    • How we made something people want
    • How we do meetings at PostHog
    • Solving the mystery of PostHog’s missing session recordings
    • Moving to San Francisco
    • How PostHog's new VP focused the company on nailing funnels in his first week
    • An engineer's guide to picking a cofounder
    • Pivot to PostHog
    • How to plan a killer company offsite in just 8 weeks
    • PostHog raises $12 million in funding led by GV and Y Combinator
    • What we learned about hiring from our first five employees
    • How (and why) our marketing team uses PostHog
    • How we rebranded PostHog in four weeks - a postmortem
    • Counterintuitive lessons about our pricing
    • I used to think you don't need product people. I was wrong.
    • What's the true role of a product team at an engineering-led organization?
    • Building an all-remote company from scratch
    • How we raised $3M for an open source project
    • All the cool things we built at our Rome hackathon
    • Content marketing strategy for devtool companies - How we do it at PostHog
    • How to seed, grow, and scale Developer Relations (and how we're doing it at PostHog)
    • Benchmarking the impact of session recording on performance
    • Speeding up PostHog builds with Depot
    • How to run finance at your startup without hiring a finance person
    • How to choose job titles in your early stage startup
    • Startups, stop treating engineers like a different species
    • The ops toolkit for early-stage startups
    • A story about pivots
    • The YC Interview
    • Why we ditched ‘talk to sales’ for transparent pricing
    • Raising money is less stressful than bootstrapping
    • What motivates me as a CEO
    • The really important job interview questions engineers should ask (but don't)
    • Why I ditched Google Analytics and Mixpanel for PostHog
    • Why infrastructure is a competitive advantage for us
    • Why we raised a $15m Series B ahead of schedule
    • Writing for developers
    • Reflecting on YC, 2 years on
    • YC adds PostHog to top valued companies for July 2021
  • Launch week
    • Introducing Collaboration for PostHog
    • Introducing Data Management for PostHog
    • What launching Experimentation taught us about running effective A/B tests
    • How we’re making PostHog deployments easier
    • PostHog Launch Week I: A Universe of New Features
    • The secrets of PostHog query performance
  • Open source
    • The Early Days of GitLab - A Chat with Sid Sijbrandij
    • The 5 best free and open-source A/B testing tools
    • The 6 best free and open-source feature flag tools
    • The best open-source analytics and data tools
    • Open source (and self-hosted) alternatives to Hotjar & FullStory
    • How we do customer support at our open source devtool company
    • How I learned to love feedback loops (and make better products)
    • PostHog Joins Hacktoberfest 2020
    • Give Back Friday with PostHog
    • Building an open source data science publishing platform - An interview with Datapane CEO, Leo Anthias
    • How we monetized our open source devtool
    • Open source is eating SaaS
    • Building an open source data stack
    • Should open source projects track you?
    • PostHog vs Amplitude
    • How we raised $3M for an open source project
    • Why open-source projects are essential for large businesses
    • Send love to open-source projects on Valentine's Day
    • Speeding up PostHog builds with Depot
    • The 3 critical reasons companies choose self-hosted analytics
  • PostHog Academy
    • What is user segmentation?
    • How to measure product engagement
    • How to achieve B2B product market fit
    • How to work out what your users really need
    • An introduction to customer retention
    • An introduction to product analytics and how it works
  • Privacy
    • The 7 best GDPR-compliant analytics tools
    • The best HIPAA-compliant A/B testing tools
    • The 4 best HIPAA-compliant analytics tools
    • Google is about to make it a lot harder to track website and app users without third-party cookies
    • A new 'Privacy Shield' won't solve big tech's GDPR problem
    • Is Google Analytics HIPAA compliant?
    • A simple guide to personal data and PII
  • Product analytics
    • Introduction to self-service analytics
    • Building an AARRR pirate funnel (how and why)
    • The two ways to estimate your monthly event usage
    • How to harness the awesome power of growth loops
    • What is user segmentation?
    • How to measure product engagement
    • How to achieve B2B product market fit
    • How to work out what your users really need
    • An introduction to customer retention
    • Is autocapture ‘still’ bad?
    • Finding your North Star metric and why it matters
    • How PostHog's new VP focused the company on nailing funnels in his first week
    • What's the true role of a product team at an engineering-led organization?
    • How to turn your engineers into product people
    • 22 ways PostHog makes it easier to build great products
    • An introduction to product analytics and how it works
  • Product updates
    • Why we're giving away 100 times more cloud usage, free
    • Enabling zero downtime data migrations for self-hosted users
    • Introducing the Avo Inspector app
    • We just made PostHog Open Source 1000x more scalable via ClickHouse
    • Introducing Collaboration for PostHog
    • Introducing Data Management for PostHog
    • What launching Experimentation taught us about running effective A/B tests
    • Group Analytics is now available in PostHog
    • You can now reverse ETL into PostHog with Hightouch
    • How we’re making PostHog deployments easier
    • PostHog Launch Week I: A Universe of New Features
    • How we’re improving performance by combining persons and events
    • PostHog teams up with Altinity
    • Introducing PostHog Cloud EU
    • Restack joins the PostHog Marketplace
    • PostHog is now available on Segment!
    • The secrets of PostHog query performance
    • Why we're removing the sessions page
    • Array 1.0.10
    • Array 1.0.11
    • Array 1.0.8
    • Array 1.0.9
    • Array 1.1.0
    • Array 1.11.0
    • Array 1.10.0
    • Array 1.12.0
    • Array 1.13.0
    • Array 1.14.0
    • Array 1.15.0
    • Array 1.16.0
    • Array 1.17.0
    • Array 1.18.0
    • Array 1.2.0
    • Array 1.19.0
    • Array 1.20.0
    • Array 1.22.0
    • Array 1.21.0
    • Array 1.23.0
    • Array 1.24.0
    • Array 1.25.0
    • Array 1.27.0
    • Array 1.28.0
    • Array 1.29.0
    • Array 1.26.0
    • Array 1.3.0
    • Array 1.30.0
    • Array 1.31.0
    • Array 1.32.0
    • Array 1.33.0
    • Array 1.34.0
    • Array 1.35.0: Introducing SAML, world map view and new plugins
    • Array 1.37.0: Cohorts 2.0 and event & property detail pages
    • Array 1.36.0: Introducing AND/OR filtering, timezone support and universal search
    • Array 1.38.0: Exports, subscriptions and session analysis
    • Array 1.39.0: Betas, persons, events and libraries
    • Array 1.4.0
    • Array 1.40.0: Interface improvements and more!
    • Array 1.42.0: Get beta features via our roadmap!
    • Array 1.5.0
    • Array 1.41.0: Improving performance by up to 400%
    • Array 1.6.0
    • Array 1.7.0
    • Array 1.8.0
    • Array 1.9.0
    • Array 1.0.0
    • The state of plugins on PostHog
  • Release notes
    • Introducing the Avo Inspector app
    • How we’re improving performance by combining persons and events
    • Array 1.0.10
    • Array 1.0.11
    • Array 1.0.8
    • Array 1.0.9
    • Array 1.1.0
    • Array 1.11.0
    • Array 1.10.0
    • Array 1.12.0
    • Array 1.13.0
    • Array 1.14.0
    • Array 1.15.0
    • Array 1.16.0
    • Array 1.17.0
    • Array 1.18.0
    • Array 1.2.0
    • Array 1.19.0
    • Array 1.20.0
    • Array 1.22.0
    • Array 1.21.0
    • Array 1.23.0
    • Array 1.24.0
    • Array 1.25.0
    • Array 1.27.0
    • Array 1.28.0
    • Array 1.29.0
    • Array 1.26.0
    • Array 1.3.0
    • Array 1.30.0
    • Array 1.31.0
    • Array 1.32.0
    • Array 1.33.0
    • Array 1.34.0
    • Array 1.35.0: Introducing SAML, world map view and new plugins
    • Array 1.37.0: Cohorts 2.0 and event & property detail pages
    • Array 1.36.0: Introducing AND/OR filtering, timezone support and universal search
    • Array 1.38.0: Exports, subscriptions and session analysis
    • Array 1.39.0: Betas, persons, events and libraries
    • Array 1.4.0
    • Array 1.40.0: Interface improvements and more!
    • Array 1.42.0: Get beta features via our roadmap!
    • Array 1.5.0
    • Array 1.41.0: Improving performance by up to 400%
    • Array 1.6.0
    • Array 1.7.0
    • Array 1.8.0
    • Array 1.9.0
    • Array 1.0.0
  • Startups
    • A non-coder's thoughts on an 'Everybody Codes' culture
    • How we found our Ideal Customer Profile
    • Creating an employee-friendly startup share option scheme
    • How to get the first 10 paying customers for your devtool company (and other customer acquisition tips)
    • How to run a transparent startup
    • Building an open source data science publishing platform - An interview with Datapane CEO, Leo Anthias
    • How we made something people want
    • How we monetized our open source devtool
    • Should open source projects track you?
    • An engineer's guide to picking a cofounder
    • How to plan a killer company offsite in just 8 weeks
    • What we learned about hiring from our first five employees
    • How we rebranded PostHog in four weeks - a postmortem
    • Product engineer vs software engineer: what's the difference?
    • What's the true role of a product team at an engineering-led organization?
    • Why you may not need a sales team
    • Don’t bother securing your trademarks in the beginning
    • Building an all-remote company from scratch
    • All the cool things we built at our Rome hackathon
    • Content marketing strategy for devtool companies - How we do it at PostHog
    • Why open-source projects are essential for large businesses
    • How to run finance at your startup without hiring a finance person
    • How to choose job titles in your early stage startup
    • Startups, stop treating engineers like a different species
    • The ops toolkit for early-stage startups
    • How to turn your engineers into product people
    • Raising money is less stressful than bootstrapping
    • What is a product engineer (and why they're awesome)
    • Writing for developers
    • Reflecting on YC, 2 years on
  • Using PostHog
    • 5 essential tips for Customer Success teams on PostHog
    • 5 analytics ideas for marketing teams using PostHog
    • 5 essential PostHog apps for new users
    • 5 events all teams should track with PostHog
    • Permissions and projects in PostHog, explained
    • How (and why) our marketing team uses PostHog
    • How (and why) to track your website with PostHog
    • What is SSO and why you should enable it for PostHog
  • Home
  • CEO diaries
    • After the HN launch
    • Remote companies can be too asynchronous
    • The time before YC
    • Winning from the back - late mover advantage
    • Optimize for not breaking up with your co-founder
    • Cancer and revenue - the latest board meeting
    • "How come your website is so nice?"
    • Things I learned last year
    • Our new objective: Nail Self Serve
    • How we found our Ideal Customer Profile
    • Tell me about features, not benefits
    • The magic of a Hacker News Pre-Mortem
    • How to run a transparent startup
    • How we justified quitting our jobs and financing PostHog early on
    • How we made something people want
    • Moving to San Francisco
    • Pivot to PostHog
    • Counterintuitive lessons about our pricing
    • I used to think you don't need product people. I was wrong.
    • How we raised $3M for an open source project
    • A story about pivots
    • The YC Interview
    • Raising money is less stressful than bootstrapping
    • What motivates me as a CEO
    • The really important job interview questions engineers should ask (but don't)
    • Writing for developers
    • Reflecting on YC, 2 years on
  • Company & culture
    • How we do meetings at PostHog
  • Comparisons
    • PostHog vs Matomo
    • PostHog vs Amplitude
    • Why I ditched Google Analytics and Mixpanel for PostHog
  • Engineering
    • Enabling zero downtime data migrations for self-hosted users
    • Automating a software company with GitHub Actions
    • How to speed up ClickHouse queries using materialized columns
    • In-depth: ClickHouse vs PostgreSQL
    • Setting up super fast Cypress tests on GitHub Actions
    • How I learned to love feedback loops (and make better products)
    • Frontend filters & backend SQL - A chat with Eric Duong, Sam Winslow, James Greenhill, and Buddy Williams
    • PostHog Joins Hacktoberfest 2020
    • How PostHog built an app server (from MVP to billions of events)
    • How we’re making PostHog deployments easier
    • Solving the mystery of PostHog’s missing session recordings
    • I used to think you don't need product people. I was wrong.
    • The secrets of PostHog query performance
    • Benchmarking the impact of session recording on performance
    • The state of plugins on PostHog
    • We ship whenever
  • General
    • Setting up super fast Cypress tests on GitHub Actions
    • How we designed the PostHog mascot
    • Why you may not need a sales team
    • A story about pivots
  • Guides
    • Introduction to self-service analytics
    • Building an AARRR pirate funnel (how and why)
    • 5 essential tips for Customer Success teams on PostHog
    • 5 analytics ideas for marketing teams using PostHog
    • Automating a software company with GitHub Actions
    • The most useful B2B SaaS product metrics
    • The 7 best GDPR-compliant analytics tools
    • The best HIPAA-compliant A/B testing tools
    • The 5 best free and open-source A/B testing tools
    • The 4 best HIPAA-compliant analytics tools
    • The best open-source analytics and data tools
    • Open source (and self-hosted) alternatives to Hotjar & FullStory
    • The two ways to estimate your monthly event usage
    • How to speed up ClickHouse queries using materialized columns
    • In-depth: ClickHouse vs PostgreSQL
    • Google is about to make it a lot harder to track website and app users without third-party cookies
    • Setting up super fast Cypress tests on GitHub Actions
    • 5 essential PostHog apps for new users
    • 5 events all teams should track with PostHog
    • What launching Experimentation taught us about running effective A/B tests
    • How to get the first 10 paying customers for your devtool company (and other customer acquisition tips)
    • The best GA4 alternatives for apps and websites
    • How to harness the awesome power of growth loops
    • What is user segmentation?
    • How to measure product engagement
    • How to achieve B2B product market fit
    • How to work out what your users really need
    • How we do hiring & HR at PostHog
    • How we turned ClickHouse into our event mansion
    • An introduction to customer retention
    • Is Google Analytics HIPAA compliant?
    • Finding your North Star metric and why it matters
    • How we monetized our open source devtool
    • Building an open source data stack
    • How to plan a killer company offsite in just 8 weeks
    • Permissions and projects in PostHog, explained
    • How (and why) our marketing team uses PostHog
    • PostHog vs Matomo
    • PostHog vs Amplitude
    • Product engineer vs software engineer: what's the difference?
    • Don’t bother securing your trademarks in the beginning
    • How to seed, grow, and scale Developer Relations (and how we're doing it at PostHog)
    • The ops toolkit for early-stage startups
    • How (and why) to track your website with PostHog
    • 22 ways PostHog makes it easier to build great products
    • What is a product engineer (and why they're awesome)
    • A simple guide to personal data and PII
    • An introduction to product analytics and how it works
    • What is SSO and why you should enable it for PostHog
    • The 3 critical reasons companies choose self-hosted analytics
  • HogMail
    • HogMail #14
    • HogMail #15
    • HogMail #16
    • HogMail #17: The personal traits that can't be taught
    • HogMail #18: What can SaaS learn from the New York Times?
  • Inside PostHog
    • PostHog raises $15 million Series B for open source product analytics
    • A non-coders thoughts on ‘Everybody Codes’ - Part Two
    • A non-coder's thoughts on an 'Everybody Codes' culture
    • After the HN launch
    • Remote companies can be too asynchronous
    • The time before YC
    • How PostHog uses Wren to offset carbon emissions during offsites
    • Winning from the back - late mover advantage
    • Optimize for not breaking up with your co-founder
    • Cancer and revenue - the latest board meeting
    • "How come your website is so nice?"
    • Things I learned last year
    • Our new objective: Nail Self Serve
    • How we found our Ideal Customer Profile
    • How we do customer support at our open source devtool company
    • The importance of dogfooding - Why product managers should use their product as much as their users
    • How we designed the PostHog mascot
    • Using Gatsby and Puppeteer to create dynamic Open Graph images
    • Creating an employee-friendly startup share option scheme
    • Tell me about features, not benefits
    • How I learned to love feedback loops (and make better products)
    • The magic of a Hacker News Pre-Mortem
    • HostHogs - free drinks, free pizza and frequently asked questions
    • How to run a transparent startup
    • How we do hiring & HR at PostHog
    • How PostHog built an app server (from MVP to billions of events)
    • How we turned ClickHouse into our event mansion
    • How we justified quitting our jobs and financing PostHog early on
    • Introducing Phil Leggetter, our new head of Developer Relations
    • Using Google Analytics was deemed 'illegal' in some EU countries. We built a microsite in 48 hours to capitalize on the news.
    • Introducing Joe Martin - Our first Product Marketer
    • How we made something people want
    • How we do meetings at PostHog
    • Solving the mystery of PostHog’s missing session recordings
    • Moving to San Francisco
    • How PostHog's new VP focused the company on nailing funnels in his first week
    • An engineer's guide to picking a cofounder
    • Pivot to PostHog
    • How to plan a killer company offsite in just 8 weeks
    • PostHog raises $12 million in funding led by GV and Y Combinator
    • What we learned about hiring from our first five employees
    • How (and why) our marketing team uses PostHog
    • How we rebranded PostHog in four weeks - a postmortem
    • Counterintuitive lessons about our pricing
    • I used to think you don't need product people. I was wrong.
    • What's the true role of a product team at an engineering-led organization?
    • Building an all-remote company from scratch
    • How we raised $3M for an open source project
    • All the cool things we built at our Rome hackathon
    • Content marketing strategy for devtool companies - How we do it at PostHog
    • How to seed, grow, and scale Developer Relations (and how we're doing it at PostHog)
    • Benchmarking the impact of session recording on performance
    • Speeding up PostHog builds with Depot
    • How to run finance at your startup without hiring a finance person
    • How to choose job titles in your early stage startup
    • Startups, stop treating engineers like a different species
    • The ops toolkit for early-stage startups
    • A story about pivots
    • The YC Interview
    • Why we ditched ‘talk to sales’ for transparent pricing
    • Raising money is less stressful than bootstrapping
    • What motivates me as a CEO
    • The really important job interview questions engineers should ask (but don't)
    • Why I ditched Google Analytics and Mixpanel for PostHog
    • Why infrastructure is a competitive advantage for us
    • Why we raised a $15m Series B ahead of schedule
    • Writing for developers
    • Reflecting on YC, 2 years on
    • YC adds PostHog to top valued companies for July 2021
  • Launch week
    • Introducing Collaboration for PostHog
    • Introducing Data Management for PostHog
    • What launching Experimentation taught us about running effective A/B tests
    • How we’re making PostHog deployments easier
    • PostHog Launch Week I: A Universe of New Features
    • The secrets of PostHog query performance
  • Open source
    • The Early Days of GitLab - A Chat with Sid Sijbrandij
    • The 5 best free and open-source A/B testing tools
    • The 6 best free and open-source feature flag tools
    • The best open-source analytics and data tools
    • Open source (and self-hosted) alternatives to Hotjar & FullStory
    • How we do customer support at our open source devtool company
    • How I learned to love feedback loops (and make better products)
    • PostHog Joins Hacktoberfest 2020
    • Give Back Friday with PostHog
    • Building an open source data science publishing platform - An interview with Datapane CEO, Leo Anthias
    • How we monetized our open source devtool
    • Open source is eating SaaS
    • Building an open source data stack
    • Should open source projects track you?
    • PostHog vs Amplitude
    • How we raised $3M for an open source project
    • Why open-source projects are essential for large businesses
    • Send love to open-source projects on Valentine's Day
    • Speeding up PostHog builds with Depot
    • The 3 critical reasons companies choose self-hosted analytics
  • PostHog Academy
    • What is user segmentation?
    • How to measure product engagement
    • How to achieve B2B product market fit
    • How to work out what your users really need
    • An introduction to customer retention
    • An introduction to product analytics and how it works
  • Privacy
    • The 7 best GDPR-compliant analytics tools
    • The best HIPAA-compliant A/B testing tools
    • The 4 best HIPAA-compliant analytics tools
    • Google is about to make it a lot harder to track website and app users without third-party cookies
    • A new 'Privacy Shield' won't solve big tech's GDPR problem
    • Is Google Analytics HIPAA compliant?
    • A simple guide to personal data and PII
  • Product analytics
    • Introduction to self-service analytics
    • Building an AARRR pirate funnel (how and why)
    • The two ways to estimate your monthly event usage
    • How to harness the awesome power of growth loops
    • What is user segmentation?
    • How to measure product engagement
    • How to achieve B2B product market fit
    • How to work out what your users really need
    • An introduction to customer retention
    • Is autocapture ‘still’ bad?
    • Finding your North Star metric and why it matters
    • How PostHog's new VP focused the company on nailing funnels in his first week
    • What's the true role of a product team at an engineering-led organization?
    • How to turn your engineers into product people
    • 22 ways PostHog makes it easier to build great products
    • An introduction to product analytics and how it works
  • Product updates
    • Why we're giving away 100 times more cloud usage, free
    • Enabling zero downtime data migrations for self-hosted users
    • Introducing the Avo Inspector app
    • We just made PostHog Open Source 1000x more scalable via ClickHouse
    • Introducing Collaboration for PostHog
    • Introducing Data Management for PostHog
    • What launching Experimentation taught us about running effective A/B tests
    • Group Analytics is now available in PostHog
    • You can now reverse ETL into PostHog with Hightouch
    • How we’re making PostHog deployments easier
    • PostHog Launch Week I: A Universe of New Features
    • How we’re improving performance by combining persons and events
    • PostHog teams up with Altinity
    • Introducing PostHog Cloud EU
    • Restack joins the PostHog Marketplace
    • PostHog is now available on Segment!
    • The secrets of PostHog query performance
    • Why we're removing the sessions page
    • Array 1.0.10
    • Array 1.0.11
    • Array 1.0.8
    • Array 1.0.9
    • Array 1.1.0
    • Array 1.11.0
    • Array 1.10.0
    • Array 1.12.0
    • Array 1.13.0
    • Array 1.14.0
    • Array 1.15.0
    • Array 1.16.0
    • Array 1.17.0
    • Array 1.18.0
    • Array 1.2.0
    • Array 1.19.0
    • Array 1.20.0
    • Array 1.22.0
    • Array 1.21.0
    • Array 1.23.0
    • Array 1.24.0
    • Array 1.25.0
    • Array 1.27.0
    • Array 1.28.0
    • Array 1.29.0
    • Array 1.26.0
    • Array 1.3.0
    • Array 1.30.0
    • Array 1.31.0
    • Array 1.32.0
    • Array 1.33.0
    • Array 1.34.0
    • Array 1.35.0: Introducing SAML, world map view and new plugins
    • Array 1.37.0: Cohorts 2.0 and event & property detail pages
    • Array 1.36.0: Introducing AND/OR filtering, timezone support and universal search
    • Array 1.38.0: Exports, subscriptions and session analysis
    • Array 1.39.0: Betas, persons, events and libraries
    • Array 1.4.0
    • Array 1.40.0: Interface improvements and more!
    • Array 1.42.0: Get beta features via our roadmap!
    • Array 1.5.0
    • Array 1.41.0: Improving performance by up to 400%
    • Array 1.6.0
    • Array 1.7.0
    • Array 1.8.0
    • Array 1.9.0
    • Array 1.0.0
    • The state of plugins on PostHog
  • Release notes
    • Introducing the Avo Inspector app
    • How we’re improving performance by combining persons and events
    • Array 1.0.10
    • Array 1.0.11
    • Array 1.0.8
    • Array 1.0.9
    • Array 1.1.0
    • Array 1.11.0
    • Array 1.10.0
    • Array 1.12.0
    • Array 1.13.0
    • Array 1.14.0
    • Array 1.15.0
    • Array 1.16.0
    • Array 1.17.0
    • Array 1.18.0
    • Array 1.2.0
    • Array 1.19.0
    • Array 1.20.0
    • Array 1.22.0
    • Array 1.21.0
    • Array 1.23.0
    • Array 1.24.0
    • Array 1.25.0
    • Array 1.27.0
    • Array 1.28.0
    • Array 1.29.0
    • Array 1.26.0
    • Array 1.3.0
    • Array 1.30.0
    • Array 1.31.0
    • Array 1.32.0
    • Array 1.33.0
    • Array 1.34.0
    • Array 1.35.0: Introducing SAML, world map view and new plugins
    • Array 1.37.0: Cohorts 2.0 and event & property detail pages
    • Array 1.36.0: Introducing AND/OR filtering, timezone support and universal search
    • Array 1.38.0: Exports, subscriptions and session analysis
    • Array 1.39.0: Betas, persons, events and libraries
    • Array 1.4.0
    • Array 1.40.0: Interface improvements and more!
    • Array 1.42.0: Get beta features via our roadmap!
    • Array 1.5.0
    • Array 1.41.0: Improving performance by up to 400%
    • Array 1.6.0
    • Array 1.7.0
    • Array 1.8.0
    • Array 1.9.0
    • Array 1.0.0
  • Startups
    • A non-coder's thoughts on an 'Everybody Codes' culture
    • How we found our Ideal Customer Profile
    • Creating an employee-friendly startup share option scheme
    • How to get the first 10 paying customers for your devtool company (and other customer acquisition tips)
    • How to run a transparent startup
    • Building an open source data science publishing platform - An interview with Datapane CEO, Leo Anthias
    • How we made something people want
    • How we monetized our open source devtool
    • Should open source projects track you?
    • An engineer's guide to picking a cofounder
    • How to plan a killer company offsite in just 8 weeks
    • What we learned about hiring from our first five employees
    • How we rebranded PostHog in four weeks - a postmortem
    • Product engineer vs software engineer: what's the difference?
    • What's the true role of a product team at an engineering-led organization?
    • Why you may not need a sales team
    • Don’t bother securing your trademarks in the beginning
    • Building an all-remote company from scratch
    • All the cool things we built at our Rome hackathon
    • Content marketing strategy for devtool companies - How we do it at PostHog
    • Why open-source projects are essential for large businesses
    • How to run finance at your startup without hiring a finance person
    • How to choose job titles in your early stage startup
    • Startups, stop treating engineers like a different species
    • The ops toolkit for early-stage startups
    • How to turn your engineers into product people
    • Raising money is less stressful than bootstrapping
    • What is a product engineer (and why they're awesome)
    • Writing for developers
    • Reflecting on YC, 2 years on
  • Using PostHog
    • 5 essential tips for Customer Success teams on PostHog
    • 5 analytics ideas for marketing teams using PostHog
    • 5 essential PostHog apps for new users
    • 5 events all teams should track with PostHog
    • Permissions and projects in PostHog, explained
    • How (and why) our marketing team uses PostHog
    • How (and why) to track your website with PostHog
    • What is SSO and why you should enable it for PostHog
  • Blog
  • Engineering
  • Inside PostHog

Solving the mystery of PostHog’s missing session recordings

  • Rick Marron
    Rick Marron

Session Recording is one of PostHog's core features, and one of the few completely open source ression replay tools available. It allows you to see how real users use your website, mouse clicks and all. It's really cool and addictive (give it a try and you'll see what I mean).

Recently, we made a ton of improvements to the feature. To name a few, we:

  • Decreased average recording load time from ~2.5s to 700ms
  • Resolved a big bug that caused recordings to "wonk out" if a recording spanned multiple tabs or browser windows
  • Revamped the player experience to make it faster for users to get to the moment in the recording they care about
  • Improved the speed to query recordings, allowing users to search across all recordings at once (it used to be limited to a single day's worth of recordings)

But there was one fix that stood out in this quality push. Customers would often tell us recordings were missing, and we didn't know why.

This is the story of how we decreased the number of missing recordings from 15% to <1%, and in doing so, moved the feature out of beta.

Rick Marron is a software engineer at PostHog. In previous lives Rick was a Program Manager at Microsoft, and he spent over a year in Nairobi, Kenya where he developed the first publicly available real-time source for traffic data in the city using computer vision and street cameras. He's a native of Rochester, New York but lives in Los Angeles now because... sunshine. Follow him on Twitter and Github.

Measuring the issue

To start, we had to find a way to measure missing recordings. If we can't measure it, we can't know if we fixed it. But how can you measure something that's missing?

We had a couple ideas, but they all had drawbacks. The two main ones we considered were:

1. Measure how often we receive web analytics events outside of a recording: The idea is that a user should have a recording if they're sending up other events. The problem is that this doesn't account for cases when recordings are disabled, so the metric would always be < 100%.

2. Measure how often we've received data for a recording, but it wasn't complete: For a recording to be shown to users, it needs to have enough data that we can draw the entire page - we call this a 'full snapshot'. This metric would measure how often we started a recording but didn't send up a full snapshot, so we couldn't render the page for the user. Theoretically, this should rarely happen.

We decided to use the second metric because it would let us strive for 0% missing recordings. If you're curious, you can read the conversation that led to this decision in this GitHub issue.

In the first run of the metric, it showed that we were missing ~15% of recordings across PostHog Cloud users.

Checking Sentry for clues

Now that we had a metric, we started hunting for clues. What was causing the missing recordings?

The first place we looked was Sentry. There were a couple of errors in the ingestion pipeline that seemed suspicious. The most notable was a "Max data upload size exceeded" error that was firing a few thousand times a day. This seemed like it could be an obvious cause of missing recordings. If some data was not being uploaded because it was too big, it would make sense that we could not get a 'full snapshot'.

To figure out what was causing this error, we looked at data that had been uploaded which was just below our size threshold of 20mb. It looked like large data URLs of images were the cause.

To test this out, we made a filter that would remove data URLs from any payload that exceeded a 5mb threshold, and it would replace the image with an obvious placeholder.

Recording Page with SVGs

One issue we faced was that we didn't want this feature to significantly increase the size of posthog-js, but we would have to include the placeholder image in the bundle. After some discussion, we landed on the idea of using a very small SVG that could easily scale to the size of the image being replaced. You can read more about the discussion that landed us here in the PR itself.

After deploying the fix, two things happened:

  1. The Sentry error went away 🥳
  2. The missing recordings only went down a few percent 😩

Back to the drawing board.

Looking deeper

What was causing the rest of the missing recordings? With no more clues, it came time to dig through the mechanics of the code.

So, how does Session Recording work?

Under the hood, we're using the open source project RRWeb to power our recordings feature. RRWeb handles capturing what happened in the DOM, serializing it (so you can send it to your server), and then replaying the serialized data.

To decrease the amount of data that's transmitted, RRWeb works by taking a full snapshot of the DOM at the beginning of the recording, and from this point forward, it watches the MutationObserver and records only the changes to the page.

From the full snapshot, you can re-create a still image of the website, and from the mutations, you can replay how the page changes over time. This is very similar to how video compression works with "key frames" and deltas.

Solving the real mystery

With this knowledge in mind, we started looking into why we were receiving mutation data for recordings, but without a full snapshot.

Presumably, if the mutations were being sent up, the snapshot code must've already run. The mutations depend entirely on the snapshot existing in memory, so it didn't make sense that there was no full snapshot.

After a day or so of pounding our heads on the keyboard, we realized that most of the missing recording cases were on single page applications. With this clue in mind, and knowing that RRWeb takes a full-snapshot on page load, it didn't take long to realize the cause.

We were splitting recordings when a user was inactive for 30 minutes (so users don't see a 10-hour long recording). But when the split happened, we were not taking a new full snapshot.

We made a fix for this, and the missing recordings started to quickly drop.

Slow moving metrics

Because this fix went into posthog-js, and different customers upgrade at different speeds, it took a while to see the full effect of the fix in our metrics.

However, after about a month of waiting (and continuously checking the metrics 😬), the 15% missing recordings metric dropped to <1% 🎉.

With this focus on quality, we've seen the usage of the Session Recordings feature go up significantly. Weekly active users is up 2.5x, and each of those users are watching about twice as many recordings per week.

And we're not done yet, we're still working to make it even easier to find and watch the recordings that show you valuable insights about your users.

As for the remaining <1% of recordings that are missing, we're still working on that too. The going theory is that it has to do with data compression errors or slow networks, but we're not quite to the bottom of that one yet.

Read our Sessions Recordings documentation for more detailed information about the feature, or you can make an account for free to try it out yourself!

Enjoyed this? Subscribe to our newsletter to hear more from us twice a month!

Author

  • Rick Marron
    Rick Marron

Share

Topic(s)

  • Engineering
  • Inside PostHog

Feb 11, 2022

The best of PostHog.
Delivered twice a month.

Jump to:

  • Measuring the issue
  • Checking Sentry for clues
  • Looking deeper
  • So, how does Session Recording work?
  • Solving the real mystery
  • Slow moving metrics
  • Edit this page
  • Raise an issue
  • Toggle content width
  • Toggle dark mode
  • Product

  • Overview
  • Pricing
  • Product analytics
  • Session recording
  • A/B testing
  • Feature flags
  • Apps
  • Customer stories
  • PostHog vs...
  • Docs

  • Quickstart guide
  • Self-hosting
  • Installing PostHog
  • Building an app
  • API
  • Webhooks
  • How PostHog works
  • Data privacy
  • Using PostHog

  • Product manual
  • Apps manuals
  • Tutorials
  • Community

  • Questions?
  • Product roadmap
  • Contributors
  • Partners
  • Newsletter
  • Merch
  • PostHog FM
  • PostHog on GitHub
  • Handbook

  • Getting started
  • Company
  • Strategy
  • How we work
  • Small teams
  • People & Ops
  • Engineering
  • Product
  • Design
  • Marketing
  • Customer success
  • Company

  • About
  • Team
  • Investors
  • Press
  • Blog
  • FAQ
  • Support
  • Careers
© 2022 PostHog, Inc.
  • Code of conduct
  • Privacy policy
  • Terms