0:40 Ian's background and editorial role at PostHog
Alexey
Today we have Ian. Ian is a writer, software engineer, and editorial lead at PostHog, where he works as a technical content marketer. He writes about startups, AI, the internet, and writing. The reason we have Ian today is because I was doing some research into who we can invite to talk about setting up prices and the cost of things. His name came up.
I think you probably did some interviews about this topic in the past, so ChatGPT suggested reaching out to you. I did, you agreed, and it's really nice to have you here. Hi.
Ian
Thanks for having me.
Alexey
Usually the first thing I ask everyone is to tell us about your background. Can you tell us about your career journey so far?
Ian
Yeah, I've been at PostHog for a little over four years. During my time there, I've mostly spent it writing, which means researching what the team at PostHog is doing, what best practices in the industry are, or coming up with those best practices myself and turning those into newsletters, blogs, tutorials, and docs. Right now I'm more focused on the newsletter and blogs, and working on social related stuff. Prior to PostHog, I was doing a lot of freelance writing and freelance software development, though I was not a good software developer. I was kind of a junior level software developer, and AI is much better now than I ever was.
Alexey
Two of us.
Ian
Yeah, I'm very grateful for AI to be around.
Alexey
Even though I consider myself a professional developer, or I used to be a professional developer, you cannot compete with that. Does it even matter anymore if you're junior level or senior level, or does it just matter how well you prompt in the end?
Ian
Yeah.
Alexey
It makes us equal now. It's just a very interesting new world. Sorry I interrupted you, but I felt like I really wanted to add something to this because it's a pain many developers experience now.
Ian
Yeah, I'm basically writing a bunch about different things, including newsletters about maximizing what you get out of your token spend, trying to use AI the right way, building products in the age of AI, and a lot of AI related topics lately. This is what people want to read, but I've also written a lot about being a product engineer and building great products. That sort of stuff is a big interest of mine and of PostHog as well.
3:24 What makes a product engineer at PostHog
Alexey
I really like what you're saying, and I'm taking notes because when people ask me how I identify myself, previously I didn't know if I was a data scientist or a community manager. Now I like saying product engineer. Didn't AI leave us no choice but to be product engineers? We really need to think about the product and about the users, because isn't coding the easy part now? What do the users want, and what do the users need?
Isn't that still the difficult part? Product engineers are the kind of engineers that actually think about that. I know this is not something we wanted to cover and it's not in the list of questions that I prepared, but I'm curious since you mentioned it. To you, who is this product engineer? What is this role?
Ian
We did a lot of writing about product engineers about three years ago and have been writing about it ever since. I think PostHog throughout its entire lifespan has had product engineers, and those have been the main type of engineers we've had. These are people who care a lot about users and talk to users. They don't have a product manager telling them what to do. We do have product managers, but they're more responsible for supporting those product engineers and product teams and going deeper on specific things, like pricing, which is a big area that product managers help with.
Product engineers are doing everything it takes to build a successful product, whether that's talking to users, setting up betas, getting feedback, addressing that feedback, working on customer concerns, fixing issues that are reported, or going to events and doing demos of their product. They have the skills that you would want to see in an engineer. They're able to build across the stack, full stack, whatever it takes. They know a bit about UI, a bit about back end and API design, and how to optimize queries. They're expected to work across the stack, but also have that ability to figure out what to work on, whether that comes from talking to users or analyzing data, making good use of that data, and making good use of experimentation tools and stuff like that.
In a way, PostHog is a toolkit for product engineers, and that's how it's been for a long time. I think not everyone identifies as a product engineer. Some people identify as a founder or just an engineer, but they're doing a lot of product engineer related things.
6:08 How PostHog works as an open-source product context layer
Alexey
What does PostHog do exactly?
Ian
PostHog is basically a context layer for your product. That means we do product analytics, session replay, feature flags, and AB testing. We have a data warehouse that allows you to sync in a bunch of data from external sources like Stripe, HubSpot, and your Postgres warehouse. Then we make it really easy for people and agents, since increasingly people are interacting with PostHog through agents, to query all that data, find insights about it, check out an error and see if it has an impact on your revenue, and those sorts of things. It covers all sorts of things you need to make your product better, basically.
Alexey
Just like Google Analytics, but way more.
Ian
Yeah, it started out as open source product analytics. We've added web analytics as well over time, and then it expanded way beyond that. We compete with a whole bunch of different companies now, all doing various dev tools. A nice thing about PostHog is that we have a really generous free tier, and a lot of people use us for free, around 97% of people use us for free.
Alexey
Is it open source as well?
Ian
Yeah, it's open source as well, so you can see what we're up to and see that we're shipping a ton, basically, and we like sharing a lot of the insights. That's why I can write a bunch of great stuff, because we're pretty open not only in our code but also in our insights. We have an open handbook, and I can write about how much something costs without having to get 20 people to approve it. I can just say, "Oh yeah, one day this cost $10,000," and that's not scary or anything like that.
8:05 Building the product engineering muscle through user feedback loops
Alexey
One thing I really liked from what you said about the product engineer role is that these product engineers have the ability to figure out what to work on. That's not something we are born with, is it? It's not something we learn at university either, because I don't remember studying these things when I was at university. Eventually I figured this out, I guess, but there was no proper program that would teach me this. I wonder, how do I actually develop the ability to figure out what to work on?
Is it through analytics, like you said PostHog can give us? Where do I even start looking? Is there a roadmap I can look at to get these skills?
Ian
In one way, we've written up a big product engineer handbook. We wrote a product engineer blog post that did really well, so we expanded it into a full handbook, and that's one way. I think probably the better way is a feedback loop where you build something, get feedback on it, specifically ask for feedback from people, ask or talk to users about some specific product or feature, or look at your analytics to see how it's doing. Then you make a hypothesis about what you should build next, and you do that in a circle. Repeatedly going through that process builds up a lot of the product engineering muscles.
Having that contact with reality is what I see from a lot of our product engineers. They're on X asking people for feedback all the time, building something, and checking whether it solved their problem and whether people are actually using the feature. They also go through some of the more advanced product questions, like how to price the product. Just like getting better at coding, it requires reps doing it, basically, and you have to put yourself in a position to be able to get that feedback, which maybe is easier with side projects for some people. At PostHog, the engineers are interacting with users, building because of it, and doing that repeatedly, and that's how they build that product engineering muscle, I think.
Alexey
Are all engineers at PostHog product engineers, or do you have usual back end engineers?
Ian
Most of them are product engineers. We have some people who are infra specific or security specific, but even then, they're working on features internally. For example, we have an internal hosting platform that allows us to spin up vibe coded apps and put them on this secure internal hosting platform, and that was put together by the infra team. They're still product engineers working on that product. Similarly, the DevEx team are product engineers, except their audience and their users are the developers at PostHog.
There are some people who would consider themselves infra engineers or something like that, or people working very heavily on the back end, like the query performance teams we've had in the past. Even so, they're still product engineers. I think a majority of people would consider themselves product engineers.
11:44 When AI features and agents cause surprise bills
Alexey
Cool, I think I invited you to the wrong interview. It should have been about product engineering, so if you like this interview and would like doing a follow up, this could be a really cool topic. The reason we met today is to talk about a different topic, though actually what I want to do with the courses we teach at DataTalks.Club is to give people the tools to be product engineers. One of the courses we have is a free course about using AI as dev tools, which we call AI Dev Tools Zoomcamp. The idea is this agentic engineering stuff, teaching how to use all these coding agents to create a good product.
We have the technical part there, showing how to use Claude, how to use Codex, how to prompt your agents, and in what sequence to build the product. This is all from the technical side of things, so we're not talking about the product side of things. That is what I want to fix and also cover in the upcoming courses, so perhaps we should arrange a follow up. Coming back to this course, when we start using AI, AI can surprise us and not in a good way. Recently I was working on a small tool and decided to use serverless.
Ian
Mhm.
Alexey
I was using Cloudflare Workers, I believe. Cloudflare Workers costs about $5 per month or something, so it's pretty cheap. Suddenly I realized there was a bill for me for one day for $50. On a company scale of spending, $50 might not seem like a big deal, but for me, if I pay only $5 per month, a 10x increase makes me wonder what's happening. The reason for that was that the agent started experimenting and sending super fast requests to one of the services.
The free tier was quickly exhausted, and I ended up paying $50 because I intervened and stopped it early enough, though had I not, it could have been a lot more. Of course it's only 50 bucks, and I learned it not quite the hard way, since it could have been worse. Do you have any similar stories like that you can share?
Ian
Yeah, we have a whole bunch of AI powered features, so that's one area where it's really easy to quickly run up costs because users are using them in all different ways. We've had cases where some AI cost has doubled overnight, going from $5K to $10K overnight.
Alexey
A lot more than $50.
Ian
Yeah, there are many cases where something like that happens. For instance, our wizard has thousands of runs per month, and each of them was costing about $7, so that can add up quite a bit. It's even worse when you're not sure where the AI spend is coming from, which has happened in the past. We've had moments where we're spending a lot, but we don't really know who exactly is spending it or what tools it's being spent on, which has happened before as well. There are plenty of cases where AI spend specifically has been quite significant.
15:48 Side project insurance, rate limits, and absorbing viral costs
Alexey
You have this AI Wizard, don't you? Let's say my agent discovers this feature, AI Wizard, and starts bombarding it with questions, and then I wake up with a $7,000 bill. I think to myself, what am I going to do and how am I going to pay, especially if I'm running a bootstrapped business and don't have the money to pay? Then I reach out to you saying, "Hey, that has been a mistake, can we somehow rectify it?" Is that how it happens, or do you say, "Sorry, we want to have this $7,000"?
Ian
I think there is a mix of things there. One nice part about the Wizard is that we pay for the inference of the Wizard.
Alexey
The Wizard?
Ian
Yes, we pay that $7 or however much it is. I think it is less now, but we pay that amount to get PostHog set up in your project, so you do not even need to ask your agent to do that. A lot of people are also using their own agents, and PostHog is perfectly usable through your own agent, which is really nice. Another thing that happens if you have an implementation issue is that some project goes viral.
We do not really want to be in the business of bankrupting small developers or anything like that. We have had plenty of cases where someone has gone viral because they do not have an optimal setup and just YOLO their setup, so they end up with a big bill. We have something called side project insurance where, if that is the case, we will just refund the bill for PostHog related events or things like that. Around some of the AI features, we have more rate limits and other limits set.
We have tons of billing limits internally. I think we automatically set one for AI, whereas on the other ones, because companies can quickly go over the limits, maybe we do not set those up immediately. They are all there to set up for people. That is the different way we do things around surprise costs.
Alexey
That is very nice of you, but in the end do you still pay the bills? Say I YOLOed my setup, somehow went viral, and 10,000 people came to my website. Maybe 10,000 is too little, so say a huge amount of people came to my website at the same time, which resulted in a big cost. Because you are so kind and have this insurance, you helped me absorb the cost. In the end, did you still have to pay your AI provider or your LLM provider?
That is very nice of you, and not everyone is doing that. How do you justify it internally?
Ian
I think the nice thing is that usually it is not LLM costs that we are paying in this case. A lot of people are using their own LLMs, and we do put limits on LLM usage.
Alexey
Do you hard cut it?
Ian
Yes, PostHog is perfectly usable without AI. We built PostHog pre AI, so you can still run all the queries, use feature flags, and use experiments. Everything works without AI, and you can bring your own AI. Where people mostly accidentally run up costs is on events and other types of data that they capture into PostHog, rather than AI spend. We even have a startup plan that gives 50k in credits for the year for startups.
For us, paying the costs on these sorts of things is worth it. We have a humongous free tier, so 97% of people never pay. If we were trying to optimize getting every single dollar possible out of everyone, we are just not set up for that at the moment.
20:13 Monitoring AI spend with observability from day one
Alexey
It is good that the company still grows despite that, which is a very good position to be in. If I am running a small company, how do I monitor this cost? It is one thing that you are nice and can help me fix the bill issue because you have this insurance. OpenAI or Anthropic might not have this, though. How do I actually make sure that before my launch I do not just YOLO my setup, and instead do something proper so I do not end up bankrupting my company because of one viral launch?
Ian
We have an AI observability feature that we use, which is also a product of PostHog, and it auto captures all of the costs. It is a very simple setup, and you can set it up with the Wizard as well. It automatically captures a bunch of details about your AI usage, including traces, costs, tokens, latency, and all those sorts of things you would want to know about how your AI features are performing. You can then set up alerts and similar things on top of those costs if that is the number one thing you are concerned about and you have not set up a billing limit in Anthropic. That is the way we do it at PostHog, and it is what we wish we had at the very beginning when we were building the first AI features so we could do all the optimization work around costs later.
Alexey
Why did you say you wished you had it? Is there a story you want to share?
Ian
When we were first building PostHog AI, we did not have any of the cost data or much AI observability because we were building those two features side by side. Very early on, when we were messing around with AI about three years ago, we were building on GPT 4 models or similar older models. The first PostHog AI assistants were very specific, like asking a question and getting back a query or a trend, rather than being as open as an agent is now. We maybe had some logs, but we did not connect those with costs. We did not have LLM observability, or AI observability as it is now known.
Because of that, it was tough to figure out how we should price these sorts of things and how much we should push them. For a long time, PostHog AI for asking questions just did not cost that much for us, and the power users were not spending that much. We did not have the super expensive models that we have now, and people got their answers and went back to their own agent where they would spend more money. Where costs became more important was when we had features doing self driving and agents running on their own, along with coding features where PostHog can write code changes. That is when getting all the details on costs matters a lot more for us.
Alexey
What you built three years ago was a simple chat assistant where people could ask a question and get an answer. Was it simple RAG or something like that?
Ian
Mhm.
Alexey
So you did not really do observability, you would just check the bill and see that it was fine for you.
Ian
Yeah.
Alexey
Was it when you started introducing more features that you noticed the bill started growing?
Ian
Yep.
Alexey
How did you go about fixing this?
Ian
I do not think it is necessarily a bad thing. Premature optimization was not something we wanted to do. It was a lot better to get people to just use it and see how they use it. It was also a lot more valuable for building a quality assistant if they used it more, so we did not want to constrain that.
Alexey
Mhm.
Ian
That was okay because it was not very much. We had a beta program, so we only let in certain people. If anyone was abusing it, we would just reach out to them. It was small enough and the team was small enough that we could do that, and back then agents were not good enough to do everything themselves as the primary way of using PostHog. As people do more things with agents all the time and have agents run for longer, it became more important for us to figure out costs.
25:42 Why pricing AI features is still unsolved
Alexey
You mentioned pricing so many times. You mentioned that product engineers work with product managers, and product managers help figure the pricing out. Product engineers are also active on X and social media, asking questions like what people think about the products or what the pricing should be. Now you mentioned it again, along with a few other times I do not remember by now.
If I have a feature or an agent like that, how do I even decide how to price it? First of all, I want to make sure that it is something useful, but then how can I price it? In books they say you should charge for the outcome rather than the alternative, meaning how much solving this problem costs the user. It is not necessarily just your AI bill, though that should also be incorporated. How do you even go about this?
At the beginning it was not a problem for you, and maybe it was all just free, but when you started adding agents and agents started doing more, you started thinking about how to price it. You also mentioned the beta program. Can you tell us more about your thinking process and how you arrived at the pricing you have right now?
Ian
The answer is that we are still figuring it out. I do not think we have the right pricing yet, and we are still working on it internally. We still have work underway around AI pricing because it is really hard, and it is not usually as clean as Intercom or Fin saying a closed ticket costs $3 or $5. For a while we were doing a lot more related to coding agents.
We were doing all the research autonomously, where your data would come in, we would do a bunch of research, and then we would put out a pull request. We said output based pricing means we should charge on this pull request. It turns out people were not really that interested in that pricing.
Alexey
Were they not interested in the pull requests, or in the pricing?
Ian
Sometimes they were not interested in the pull request. Pull requests varied between a one line change to fix some grammar and a huge change, and those were priced the same. How do we even judge that? A lot of companies just use a markup on AI tokens, and that is what we have for right now. I think we are at a 20% markup on AI tokens.
You can still use your own agents to do all the same things that our agents do. I do not think that pricing is super good either, because it raises the question of why someone would not just use their own agents. We do not have the full answer, and AI pricing is something I do want to write about eventually, but I have not written about it because we have not figured it out yet.
29:19 Free MCP access, bring-your-own subscriptions, and credit-based billing
Alexey
It is a tricky thing. You also mentioned that I can just use my own Claude, though of course there needs to be some integration like an MCP, CLI, API, or another way for me to interact with the platform. If you provide that, is there no cost for you in terms of AI tokens? The cost could be different. Do you currently charge for this access to MCP, CLI, or other integrations?
Ian
No, you can use those for free. We even have a bring your own subscription option.
Alexey
Mhm.
Ian
It is a feature where you can log in with your Claude or Codex subscription and run our scouts, which are basically our long running agents that look over all your data, make reports, and suggest changes. You can bring your own subscriptions to do that sort of thing. We do not charge for access like that.
Alexey
What is your plan then? It definitely costs you money, or there is probably some opportunity there, so I do not know what you are thinking. Are you just figuring out how people use it right now in order to answer this question later, or what is the plan?
Ian
Our product managers have been working on that for a while, and our AI pricing and billing teams have been working a lot on figuring this out. I do not know all the details of what will come. I know we are not going to charge for MCP access, because we already charge for ingesting different types of events. You might have product analytics related events, web analytics related events, AI observability events, survey events, or feature flag requests, and we have a free tier for those before charging. All of our different products have their own free tier.
For PostHog AI, we just have credit based pricing for now. Figuring out how that works is tricky because the margins, usage, and costs are totally different between AI and other areas. Right now we have a lot of our product pricing figured out, though new products are coming and changes are required. Sometimes we want to make the free tier more generous or change the pricing, and that evolves over time, while AI is sort of its own area. Whenever I see other people charging for AI, it is always either credits, which are basically tokens, or something equivalent to tokens.
I do not think that many people actually have very good outcomes based pricing. We are still working on it. I do want to write about that, so hopefully that will come soon.
32:38 Launching an AI product safely without going bankrupt
Alexey
Okay. So I have an idea, and plenty of people who listen to us also have ideas. Many of us already start implementing these ideas, and this is what we also teach in the course. At some point we implement this idea, and it often involves AI. For example, one of the ideas I have right now is for AI engineering system design.
In AI engineering interviews, you have different stages. One of these stages is AI system design, where you need to design a system for doing something. Let's say you want to design a system for making pull requests, or a system for setting up agents at PostHog. How do you design an agent that would set up an account for this specific business? How do you go about this?
There are interviews where companies ask this. So I want to create a kind of gym, an environment where you have a whiteboard where you can draw the diagram. Then on the right side, you have the interviewer. The interviewer is asking you questions, you answer, and you have one hour to finish the assignment. Isn't this a cool idea?
The reason it's not public yet is that I'm afraid. If I make it public and somebody discovers it, I end up with a big bill. So then I have to do registration. If I do registration, how do I make sure people don't abuse it? At what point do I stop making it free and actually have people pay?
What if people create many accounts and continue using the product for free to avoid paying? All these questions are in my mind, and I think I'll just keep it closed and not open it to the world. So how can I actually start a product with an AI feature? How do I go from an idea to a launch? What are the main stages there, and how do I do this?
Ian
Yeah. Again, I think it is tricky, and I don't know if I have the best advice for that one. Obviously, monitoring from day one and having that in place around knowing what your costs actually are and your cost per user is key. Having things in place to protect against abuse is also a big aspect of it, because people will try and figure out if they can just call your API endpoint and get you to respond to arbitrary queries. Having things in place to protect against that matters, and I think using cheaper, worse models in places where you can, or routing to those models, helps too.
Something that we do is we have a Slack app that allows you to use PostHog however you want through Slack. We use one of the decision models, something like Jev, to decide what model we should send this request to. Someone will ask a question, it will quickly decide which one we should send it to, and then it will use that model to do it. So if it's a very simple thing, it will use a cheaper model.
Alexey
It's a good use case for Jev from what I hear.
Ian
Yeah. It was super interesting researching our team and figuring out how they use those models specifically, and I think that's a really good use case for them. One thing that I do know is that AI products just have to be more comfortable charging for what they produce earlier. Especially if you're working on this as a side project, or you're a small business or an indie hacker, we're not in the era of not charging, seeing if you get a big audience, and then raising VC and doing that whole thing.
Alexey
With AI it's just not feasible, because okay, I have an audience, but what if it goes viral? If I have a free tier, then I go bankrupt.
Ian
Uh huh.
Alexey
With AI, isn't that true?
Ian
I mean, I think people have waitlists and these sorts of things as well. Putting limits on the Anthropic spend and just knowing that it's going to go down at some point helps. Then you can use all the data that you collect from the actual usage of it to optimize that spend to a place where you're comfortable, and you understand a bit more about how much a session costs and the conversion rate of different sessions and stuff like that. It's about spending enough that you collect the data, and then being confident that once you collect that data, you can go back and optimize the entire funnel towards conversion and AI spend.
So maybe it's just charging from the very beginning. Something we do is we basically have a free tier and then we have pay as you go, which also gets the same free tier, and the difference is that you enter your credit card. For the free tier they're quite limited with their AI usage compared to events, where we'll let them capture a million events or try to capture more than that before dropping those events. But the AI spend is $5, that's our cutoff for AI spend, and we don't let them go over or do overages. That's something that we do just because it's really easy to run up a big bill really quickly with AI.
Alexey
Okay. So I want to summarize, because you provided a lot of information and I want to make sure that I didn't forget anything. First of all, monitoring from day one so you know cost per user and cost per session. You do this by letting people use your app, and because you have proper monitoring you can capture all that. Then of course it also helps to have protection against abuse, making sure all the endpoints are closed behind some sort of protective mechanisms so people who want to use your LLMs can only use them for the purpose you want.
Then you also recommended using cheaper models and using Jev for routing. Plus start charging from day one and think about how exactly you can charge. For example, it could be pay as you go. In my case, if I have this system design gym, people can use it, and if they go extra, I can add API spend on top of their normal plan, or something like this.
Ian
Yep.
40:11 Using waitlists and feature flags for alpha and beta rollouts
Alexey
Okay, how would you go about the waitlist? I think the waitlist is a very nice idea, something I didn't think about because it creates a kind of buffer. In engineering we have a message queue. When there are a lot of events, we don't want to kill our database with these events, so we queue them in a message queue and then we pace them out. A waiting list is kind of the same thing, but for products, so how do we organize it?
Ian
So we do a lot of alpha and beta testing. Since we have lots of customers, we have lots of people who want to just use these new things, and then we let them in and are carefully able to monitor what they're up to and make sure it's not getting out of control. We trust these people because they're already customers, we're already familiar with them, and we know they're not going to be super abusive to it. We generally use feature flags, just more PostHog products basically. We use feature flags a ton to manage beta and alpha and prereleases.
Alexey
Sorry for interrupting you. Let's say I have my user base, and it's 100%.
Ian
Yep.
Alexey
Out of this 100%, you reach out to some people saying we have this feature, or maybe you send it to the entire mailing list asking if they're interested in trying it. Then for the people who want to try it, you enable the feature flag for them.
Ian
Yep.
Alexey
You say for these people, they are our alpha group, and it could be 0.1% of your entire user base, and you just go and turn on the feature flag. So now the next time these users log in, they have access to this feature. You monitor how they use this feature, what they do with it, how much they actually spend on it, or how much you spend on letting them use the feature. Then you use this to learn and open it to beta users with the learnings you had from the alpha testing. Again, you use the feature flag to gradually go from there.
Ian
Yeah. A nice thing is that since feature flags are connected up to analytics, we can filter all the analytics for people who have a specific feature flag value, which is really nice. We can look at sessions or agent sessions for people who have that feature flag value. That allows us to do all of our reporting specifically for that group, even if we have a lot more people using all different types of products, so we can narrow in specifically on the beta users. We can even see how they're using other products as well, which is really nice.
43:07 Key product analytics: activation, retention, and session replays
Alexey
Mhm. How can I make the most of this analytics as a founder, indie hacker, or for my side project? I have this project, and how do I make the most of analytics to make data driven decisions when it comes to pricing among other things, and also my costs for LLMs and other things? What kind of must have setup do I need to have so I'm not in the dark when it comes to all these decisions?
Ian
I mean, PostHog autocaptures a lot of things, which is nice, so you can start with a really wide net. I think narrowing in on some specific metrics you should care about, like signups and activation, is important. There are ways of figuring out activation based on retention. Activation is basically your product's aha moment, the moment someone gets it, or more technically, where they are more likely to be retained.
Alexey
So I have a user, and this is the lifetime of a user. We always have the probability of churning, because the user might decide it's not their thing or it's not solving the problem. At some point in their lifetime, they realize they actually got this, it is useful, and it's solving their problem, and then the probability of churn goes down. So this is the aha moment.
Ian
Yep.
Alexey
They think, okay, I get it, this is useful for whatever problem I'm solving, so I'm sticking around.
Ian
Yep.
Alexey
Okay. Is this different for different products? So you have to somehow define it.
Ian
It is different. You definitely need some data on retention, like week over week, how many people are coming back to your product. If it's a product to come back to, maybe your dojo classroom is one that doesn't have so much retention because the product works. It might be a more expensive upfront payment, where we're just getting a whole bunch of new customers and not caring so much about retention. Then you would care about how much you're paying per customer, both in terms of paid spend and in terms of AI spend.
You care that they're getting through to conversion and finding value there. Getting feedback from them and seeing if it actually helped them in their interviews, getting that broader sort of feedback, is also important. The tricky thing about analytics is that everyone's metrics are sort of different, so it's difficult to recommend what exactly to do. Setting up your activation metric is important, and looking at session replays is something that we recommend. Session replays are basically getting a view through your user's eyes on how they're using the product.
Alexey
How does it look in practice? So I have a session, then I can click play, and it would show what exactly was happening?
Ian
Yep, where they clicked, where they got confused basically, or where they scrolled, all these sorts of things. I think a lot of early stage founders find this one of the most useful PostHog features.
Alexey
Do you also capture the mouse position, the cursor position?
Ian
Yep.
Alexey
Okay. So basically it's a 100% replay of all the actions that they did within the session.
Ian
Yeah, it automatically blurs out some privacy stuff. You can set up all of that as well, and you can set up filters too. It doesn't take a video directly. It captures the DOM and rebuilds the DOM through history basically.
Alexey
Makes sense.
Ian
We actually have a feature even now called Replay Vision, where an AI watches replays for you. We basically go through a pipeline that recreates these replays as videos, and then we send them through a video model that can watch video, like Gemini models, which are good at watching video actually, to figure out what users are doing. We have different scanners you can set up to look for specific things, like where users got frustrated or where users ran into bugs that they shouldn't have. Then you can find those specific sessions and watch them yourself, or you can even have your agent pick up the reports from those scanners.
Alexey
This is a super interesting thing. You turn this session replay into a video and then you just dump a bunch of videos to a video model and say, "Figure out where users get confused or frustrated." Do you specify more than that, or do you just say, "Here is a bunch of videos, see where the users in these videos are frustrated and figure out why," or do you give more information?
Ian
It's up to the users, so they can set their own scanners.
Alexey
Do you have best practices?
Ian
We have templates to do it, and I think those are some of the most commonly used templates for Replay Vision.
Alexey
So what you give is a document that describes how they should do this, and then they go and use their Gemini subscription for doing this?
Ian
I mean, we have it built into PostHog, so that's how we do it basically.
Alexey
I see. How much do you charge?
Ian
It depends on what model you use.
Alexey
Is it for tokens in this case?
Ian
Yes, I think so. It depends on what model you use.
Alexey
So Sonnet is more expensive than Haiku.
Ian
I think it doesn't even use those models because those models maybe don't have the video watching capabilities.
Alexey
I see.
Ian
It uses one specific Gemini model that I'm forgetting off the top of my head, and maybe one family of Gemini models, because they can watch videos really well.
50:01 AI session tracking, error tracking, and MCP intent analytics
Alexey
Okay. Coming back to the analytics questions, you say we need to capture things like signups and activations. It's also useful to check session replays. Besides signups and activations, what other metrics should we capture? Aha moments are important, but we also need to define them, so what else do we watch to see that we're getting traction?
Ian
I mean, you also have the sorts of things around AI because lots of people are using AI. You're capturing your AI sessions similarly.
Alexey
Do you mean all the conversations with AI, all the messages, and all the tool calls?
Ian
Yep, exactly. You can go through those sessions as well in PostHog, and we also have error tracking. I think early on it can be really valuable, especially for AI products, to fix bugs basically. For example, when it comes to AI costs, one of the worst costs is a session that breaks, bugs out, and errors out because the user got no value from it and it costs you money. So being able to fix those sorts of things is really important.
Alexey
Mhm.
Ian
Another area where we have analytics that I think is going to be a rising area of analytics is MCP analytics. Basically, we have the ability to capture analytics about your MCP server, like which tools are being called and also the intent behind the tools. Maybe a human won't tell you what they're intending to do, but an agent will tell you, "Oh, I'm trying to get this resource and I'm asking about this sort of thing." Then you can learn a lot about which tools they like to use, which tools are maybe missing, and make your MCP server a lot better. That makes your whole product better for agents, so that's another area of analytics that we find really useful.
Alexey
I'm really curious about the last part, discovering intent. Okay, the agents will tell, but do you really see this, and how do you get access to it? Is it because it happens on your platform that you see all these traces and all the reasoning? I guess if I bring my own model and my own subscription, it happens on my side, I just make the calls to MCP, and what you see are just MCP calls. You don't really see the reasons why the model decided to call the MCP, so how does it work?
Ian
I mean, we have our MCP server, and when it's interacting with the MCP server, it's encouraging the model to share its intent when using the MCP server basically.
Alexey
So you add a parameter in the tool?
Ian
So there's an MCP intent property that we capture.
Alexey
That's very smart. So basically, in order to invoke the tool, the agent must tell you why, what the reasoning is behind the invocation.
Ian
Yeah.
Alexey
Okay. Do you make it optional?
Ian
I'm not sure to be honest. I don't know the exact implementation detail.
Alexey
It actually opens so many things to check, doesn't it? I also develop with tools, and sometimes I have to explicitly ask the agent, "Okay, you completed the task, but were there more optimal ways to do this if you had other tools?" The agent would say, "Actually, this is what I needed, but it wasn't there, so I had to do it this way." Then the path is longer, whereas if it had those tools, it would have been shorter.
So then the agent says, "This is what I need," and it gets implemented. Can't you do this sort of retrospective after each session? You have to ask the agent or somehow program it so it does this automatically. Here you can incorporate it into the tool, and this is really smart.
Ian
Exactly, yeah.
54:17 How PostHog gets recommended by AI assistants (SEO and word of mouth)
Alexey
That's cool. Okay. I think now if I ask OpenAI what kind of analytics I should use for my project, it will recommend PostHog.
Ian
Mhm.
Alexey
How did you do this? How did you get AI to recommend it?
Ian
I mean.
Alexey
Is this your work? You said you write a lot, and I suspect that the company has to thank you for ChatGPT recommending these things, so tell us your secret.
Ian
It's not just me, we have lots of other marketers as well. First, it's largely SEO, the past generation of marketing trying to optimize your website to show up on Google Search. It turns out that agents also use search to decide these sorts of things. So ranking towards the top for various search queries is really helpful.
I think also we have a really strong brand and a lot of word of mouth growth, and that shows up in lots of different places. We just have lots of people recommending us wherever they are, on social, online, on Reddit, these sorts of things. We haven't really optimized super hard for asking people to share us online or anything like that. People have just done that naturally over time. That gets added into the training data and into the places they check, and then we show up for analytics basically.
I think those are the two big ways and two big reasons why, and those have been happening for many years now. It's not like three months ago we decided we wanted to rank at the top for analytics. I think that would be very tough, if not impossible, because the training data also lags by six months or whatever. So even the built in training data is going to recommend something based on the data it has from six months ago. It'll use search, and we want to be near the top for search, so that's kind of how we do it.
56:28 Choosing content topics and SEO/AEO tools at PostHog
Alexey
Mhm. How do you decide what to work on next? What kind of piece of content do you write?
Ian
A lot of it is what I'm interested in. For example, we were talking a lot about AI pricing, and I really want to write about AI pricing once we figure that out because a lot of people have these exact same questions.
Alexey
I was kind of hoping that you already figured it out, came to this podcast, and told me everything.
Ian
Yeah, I wish.
Alexey
When you figure this out.
Ian
Yeah, when I write that piece I can come back and try to give you as many answers as possible. So it's what interests me, what I see out there that people are struggling with or asking about, what I think is going to perform well, and what we have strong opinions on. I think a lot of people at PostHog have very strong opinions about various things, like what you should actually be doing with agents. We're very on the cutting edge, I think, of actually using agents.
Maybe we're not Anthropic or OpenAI, but we are a company that's using agents a ton for development and building a successful product along the way. We can share those lessons of everything that we've learned about using agents, how to write skills for agents, or how to have long running agents do dev chores for us. Stuff like that can help people a lot, whether they're early stage founders or product engineers at bigger companies. That's kind of the stuff I like to write about and want to write about.
Alexey
Mhm. So it's mostly interest driven. You are interested in these particular things, you want to write about them, and this is what the company is also doing, so you want to help, capture that, and write. I was thinking maybe you have a tool that would say, "Hey, this week you need to write this piece of content in order to rank higher on Google or whatever." Do you use anything like that?
Ian
Not for this specific content. I'm working on a lot of newsletter content, for example, which is not really meant to rank for SEO and AEO related content. We do have tools that we use. We use PostHog for some of the data, and we capture a bunch of data into PostHog, like Google Search Console.
We have a tool called Gauge that we use for AEO and tracking our different prompts. We use Ahrefs for traditional SEO related stuff. I love a tool called Keywords Everywhere, which is just a really cheap Chrome extension that I think everyone should use to see what the search traffic is for different keywords in Google.
Basically, Google tells you this data, and that could be a proxy for how many people are searching it up in a way. You can reasonably assume that a similar amount of people would be querying that in ChatGPT or whatever, so writing something about that could be valuable. That's for a specific genre of content, the SEO and AEO related content, and we have those tools for that.
Alexey
How do you spell Gauge? J A J E?
Ian
It's G A U G E.
Alexey
Okay. I'm struggling to find it. Maybe you can just send the link.
Ian
Yep, yep.
Alexey
Okay, that is amazing. I took a lot of notes because I want to launch things and share how I did it with people, and this is something we also want to teach. As I said, we already have a course about using AI tools for writing code, but nobody tells us how to be good product engineers yet, do they? So we need to figure this out.
Ian, thanks a lot for joining us today, for sharing your experience with us, and for guiding us through many things. I asked you a lot of questions and this has been very useful. Once you figure out the AI pricing, please come back and tell us how to do this. You'll probably be in big demand once you do this.
Ian
I mean, the thing is it's not going to be me who figures it out. I'm just going to write about it afterwards.
Alexey
That also works. As long as you convey this information to us, it works.
Ian
Yes. I will let you know when we figure it out.
Alexey
Thanks a lot. Enjoy sunny or not so sunny Copenhagen. Actually in Berlin it's also sunny, but super cold. Have fun in Europe, thanks for joining us today, and also thanks everyone for joining us today too. It was a fun session, thanks a lot.
Ian
Thanks. It was awesome.
Alexey
Yeah, see you.