If you're working with a Single Page Application (SPA), setting up the Google Tag correctly is crucial. In SPAs, page transitions happen without a full reload, which is why tracking based on History Change is one of the best methods for accurately capturing user behavior.

Here are the top three reasons to use the update=true parameter in this setup:

1. Correctly Track URL Changes
In SPAs, the page doesn't reload during transitions; only the URL is updated. The update=true parameter notifies Google Tag that the URL and referrer have changed, without triggering a new page_view. This is essential for accurate session tracking and funnel creation.

3. Avoid False Referrals
Without this setting, you may encounter the issue of rogue referrals, where referral sources are incorrectly recorded. The update=true parameter helps prevent this, ensuring accurate attribution data. Julius Fedorovicius mentions that while Google claims to handle this automatically, manual control provides more reliability (the screenshot is from his website).

3. Automatic Event Tracking
Events like user_engagement rely on up-to-date page information. If the tag doesn’t know about URL changes, these events could be tracked incorrectly. Using update=true in conjunction with History Change solves this problem and enhances report quality.

Important: The tag with update=true should not have a trigger. It needs to be set up with send_page_view=false through Tag Sequencing so that it fires before the page_view event (the greatest piece of advice from Julius!).

If you work with GA4 to BigQuery exports, be sure to check out my SQL cheat sheet.