[ Home / About / Contact / WOTM ] [ b ] [ wd / ui / css / resp ] [ seo / serp / loc / tech ] [ sm / cont / conv / ana ] [ case / tool / q / job ]

/q/ - Q&A Central

Help, troubleshooting & advice for practitioners
Name
Email
Subject
Comment
File
Password (For file deletion.)

File: 1789773948882.jpg (125.34 KB, 1024x1024, img_1789773941724_9xnoivjx.jpg)ImgOps Exif Google Yandex

9fd95 No.2262

client's seeing double sessions because they're firing custom events before the default config loads. just move your session_start overrides into the initial config call so it doesn't overwrite the existing params mid-stream.
gtag('config', 'G-XXXXXXXXXX', {'session_start': {'user_id': '12345'}});

it's a simple tiny fix but saves the attribution from looking like complete garbage. unless you enjoy explaining why bounce rates are zero.

9fd95 No.2284

File: 1790251424271.jpg (137.82 KB, 1024x1024, img_1790251407403_a83efw2v.jpg)ImgOps Exif Google Yandex

>>2262
Are you seeing this happen with GTM triggers too? I'm trying to figure out if moving things into the config call fixes it when a custom tag fires right at the top of the container.

9fd95 No.2285

File: 1790280924223.jpg (121.24 KB, 1024x1024, img_1790280907593_nqghuto9.jpg)ImgOps Exif Google Yandex

>>2284
I've had that exact same headache with GTM. If your custom tag is set to fire on All Pages or even earlier, it usually hits before the config is ready and breaks everything. I tried just re-ordering my tags in the container once but it didn't help much. It's a nightmare when you can't trace where the extra hits are coming from. Also, OP, does this work if they're using an older version of the snippet? I'm still a bit shaky on how the timing works with the legacy stuff.



[Return] [Go to top] Catalog [Post a Reply]
Delete Post [ ]
[ Home / About / Contact / WOTM ] [ b ] [ wd / ui / css / resp ] [ seo / serp / loc / tech ] [ sm / cont / conv / ana ] [ case / tool / q / job ]