Marcus Hof

Product Engineer, PostHog

Biography

I’m Marcus, a product engineer in the cdp team. Currently working on realtime destinations and the messaging v1.

Before PostHog I was building an open-source loom alternative at Snapify and reached the front page of HackerNews using Tablane.

  • Bernhard
    6 days ago

    Error

    Screenshot 2025-02-13 at 15.59.38.png

    I always get this error after trying to login.

    • Marcus
      5 days agoSolution

      Hey Bernhard, we've had an issue migrating our environment variables to a new system, which caused issues with some of our OAuth integrations. The issue should have been resolved by now. Let me know if you are still experiencing issues.

    • Bernhard
      Author5 days ago

      Lovely works ! 10/10

  • Dana
    21 days ago

    Does the ActiveCampaign only create contacts, or will it update them as well?

    We are setting up ActiveCampaign and want to use the webhook to create contacts when they first register. We then want to update those contacts in ActiveCampaign as they complete key funnel events. Is this possible? Thanks!

    • Marcus
      5 days agoSolution

      Yes - we'll try to update the properties if the email matches an existing contact. If not, we'll create a new contact.

  • Ricardo
    3 months ago

    There is no Google Ads Conversions in Data Pipeline > Destinations

    I couldn't find any case there, are you sure it is called that?

    • Marcus
      16 days ago

      You can install the Google destination by following the steps from this comment.

  • Nik
    3 months ago

    Transferring Projects Into Other Orgs

    We acquired a company that's using Posthog and we want to move the project into our Posthog Org, is there a clean way to do that? We are owners over the exist org and the new one.

    • Marcus
      3 months agoSolution

      Hey - closing this community question as we've moved over the project in ticket #20261. You should have received an email.

  • Joe
    3 months ago

    Two questions regarding the Google Ads Conversion Integration

    Is it possible to also send the conversion value? How does it have to be formatted?

    And do I need to have Basic Access or Standard Access for my developer token? With the basic setup I only have Test Access, requesting Basic Access requires to upload documents and provide some more information to Google

  • Kevin
    3 months ago

    Get geoIP information

    In my typsecript application I want to know the Latest Subdivision 1 Code of my user. How can I achieve this using posthog's SDK?

  • Jacob
    4 months ago

    Possible to remove properties from a webhook body based upon data availability?

    I have a webhook destination where I'm posting the following body:

    {
    "email": "{person.properties.email}",
    "attributes": {
    "SEX": "{event.properties.$set.sex}",
    "MEALS": "{event.properties.$set.meals}",
    "PREMIUM": "{event.properties.$set.isPremium}",
    "WEIGHTGOAL": "{event.properties.$set.weightGoal}",
    "TARGETWEIGHT": "{event.properties.$set.targetWeight}",
    "FREEAIUSAGESLEFT": "{event.properties.$set.freeAIUsagesLeft}"
    }
    }

    If the event which triggers the webhook to fire lacks a particular property, then is it possible for me to remove the property from the body? For example, if event.properties.$set.freeAIUsagesLeft is not present in the triggering event, I would like to remove the entire "FREEAIUSAGESLEFT" property from the body of the webhook.

    • Marcus
      4 months agoSolution

      Hey Jacob, that is possible! But you'll need to edit the Hog code into something like this:

      let body := {
      'email': person.properties.email,
      'attributes': {}
      }
      let attributes := {
      'SEX': event.properties.$set.sex,
      'MEALS': event.properties.$set.meals,
      'PREMIUM': event.properties.$set.isPremium,
      'WEIGHTGOAL': event.properties.$set.weightGoal,
      'TARGETWEIGHT': event.properties.$set.targetWeight,
      'FREEAIUSAGESLEFT': event.properties.$set.freeAIUsagesLeft
      }
      for (let key, value in attributes) {
      if (not empty(value)) {
      body.attributes[key] := value
      }
      }
      let payload := {
      'headers': inputs.headers,
      'body': body,
      'method': inputs.method
      }
      let res := fetch(inputs.url, payload);
  • Jacob
    4 months ago

    How can send a webhook from posthog that is triggered when people properties get updated?

    Hello, Destinations are easy to trigger as the result of specific events occurring but I'm wondering if it's possible to trigger a webhook as a result of people properties getting updated. In my posthog implementation we have a variety of different events which contain $set properties which update different people properties and it doesn't make sense to create a whole bunch of webhooks, each triggered by these unique events. Instead, is it possible for the webhook to be triggered when specific people properties change?

    Thank you

    • Marcus
      4 months agoSolution

      Hey Jacob, in your case you'll need to use the following expression:

      isNotNull(properties.$set.isPremium)

      Note that auto-captured properties (such as $current_url or $os_version) start with a $.

  • Aleks
    4 months ago

    How to send conversion data from PostHog to Google Ads?

    We run conversion-based Google Ads PPC campaigns on multiple websites, and it's important to send conversion data to it, so Ads are automatically optimized for the right audience.

    Generally it includes the following Google-hardcoded parameters: gclid, gbraid, wbraid. GA4 automatically captures it and sync with Ads but there is no native PostHog integration in Google Ads, so I would like to know if it's possible.

  • Fabrizio
    5 months ago

    Batch exports of SQL queries

    Hi, Is it possible to set up batch exports to Bigquery of a created SQL query? Thanks in advance!

  • Sareh
    5 months ago

    DPA

    Hallo,

    I am from dormakaba. We have recently started to use the analytics for a our billing portal. Since we do not have yet any customer on the portal we are on a free plan. This is a MVP for now. but before releasing to production and try it with some customers, we need to have a DPA signed as a requirment from legal. Do you have a standard DPA for us to review and sign for the free plan?

    Thank you Sareh Zimmermann

  • Matt
    5 months ago

    Create table failed

    I am trying to set up a Data Warehouse source that is a GCS bucket where I've put a parquet file containing user attributes derived from our data warehouse data.

    I am getting the attached error. I've experimented with deliberately putting in an incorrect bucket URL and keys and I get the same error which suggests this a generic error that doesn't really give me much info about what could be going wrong and therefore how to fix. Any clue how I can proceed?

    • Marcus
      5 months agoSolution

      Hey Matt, we were experiencing an incident during your ticket. Could you try again and see if the issue persists?

  • Mike
    5 months ago

    Editing events' distinct IDs

    Hi!

    We have about three weeks worth of data with incorrect distinct IDs. Is there any way to edit events post-facto? If not, is there a way folks usually deal with situations like this so that they can still make coherent charts and use HogQL?

    Thanks!

    • Mike
      Author2 months ago

      Hi!

      Just circling back to this and wondering if this information is sufficient to move forward with the ticket?

      Thank you!

  • Vitaly
    6 months ago

    Failed to execute 'getComputedStyle' on 'Window': parameter 1 is not of type 'Element'.

    We are using PostHog version 1.139.1 for our website and encountering the following error in various browsers:

    Failed to execute 'getComputedStyle' on 'Window': parameter 1 is not of type 'Element'.

    This occurs at:

    node_modules/posthog-js/dist/es.js at line 1:98652

    We are not explicitly calling this code; it seems to be triggered automatically. Has anyone else encountered this issue, and is there a known solution?

  • Vitaly
    6 months ago

    Error in mobile safari PosthogJS

    We are using PostHog version 1.139.1 for our website. On mobile Safari, we encounter the error 'Attempted to assign to readonly property' at the following line:

    node_modules/posthog-js/dist/es.js in Y at line 1:6422

    This happens when calling:

    posthog.capture('$pageview');

    Has anyone else experienced this issue, and is there a known solution?

    • Marcus
      6 months ago

      Hey Vitaly, I wasn't able to replicate the issue. Could you update posthog-js to the current version and see if the error persists?

    • Vitaly
      Author6 months ago

      Alright, thank you. Once we update to the latest version, I'll let you know if the error persists.

  • joel
    6 months ago

    Data Export

    Is there any plan to add the Web Analytics as a possible export?

    • Marcus
      6 months ago

      Hey joel, could you share a bit more context about your use case? Web analytics insights are based on the same events, which you can export using our batch export system.

  • What element is clicked with an Autocapture event?

    Im trying to figure out what element is clicked with an autocapture event. I have a name but I dont know really what element this is. What is the algorithm for setting a name, so I can tell my product manager on how to understand the autocapture events

    • Marcus
      6 months agoSolution

      Hey Snorre, you can access the element for each auto-capture event using the following HogQL expression: arrayElement(splitByChar('.', elements_chain), 1). Check out this guide for more details.

  • Moises
    6 months ago

    Importing Emails

    Hey im having trouble finding a way to import a list of emails for marketing. I was reduced to copy and pasting a thousand emails and I would really like your help in sharing with me how to import solely the list of emails from specific data sets that I create. If you need to do it manually please let me know

    • Marcus
      6 months ago

      Hey Moises, that is not directly possible. You'll have to capture an event with the email alongside their distinct_id. Check out this guide for more details.

  • Gabriel
    6 months ago

    Importing events in Batch taking too long

    I imported a batch events, as historical migration, something about only 391 events, but it like took more than one day to import 359 events, maybe it gets on 391, but, its taking too long, stopped on 228 imported events for many hours. Is it normal, based on my plan or something? I search on the docs for something but didn't found nothing.

    • Marcus
      6 months ago

      Hello Gabriel,

      Sorry for this. Due to how our system ingests events, we have a distributed table created in our ClickHouse cluster to store events. Sometimes the queue of that table (https://clickhouse.com/docs/en/operations/system-tables/distribution_queue) grows a lot and instead of taking seconds or minutes to dump the events into the events table, it could take several hours.

      Just wanted to let you know that no data is lost or missing, it is just that there is more lag than usual currently. Furthermore, we are already working on a solution so this problem is completely gone.

      Meanwhile, we are monitoring it and will update the status page in case the lag persists.

      Apologies for any inconvenience caused by this.