Next.js Discord

Discord Forum

Is there any generic way of passing the UTM Param on route change?

Unanswered
Transvaal lion posted this in #help-forum
Open in Discord
Transvaal lionOP
Hello everyone! I'm seeking guidance on an issue related to UTM parameters in URLs. Let's say I have a website, and users often land on a page with a UTM parameter in the URL (ex., "mywebsite.com?id=ab12"). I'm looking for an efficient method to ensure that as users navigate through different pages on the site, this UTM parameter is consistently passed along without the need to manually append it to each link within the site. Is there a universal | | automated | | generic strategy for passing specific UTM parameters through all route changes? Ideally, I'd like to avoid the labor-intensive process of manually updating every link. Any advice or insights on how to achieve this would be greatly appreciated.

0 Replies