https://developers.google.com/analytics/devguides/collection/analyticsjs/field-reference#referrer
I can set google analytics referrer manually with ga script. but I want to use gtag script for GA implementation. So How can I set the Referer manually using gtag script?
I tried this. but events are not hit with the referrer I set.
<!-- Add gtag -->
<!-- Global site tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js"></script>
<script>
window.dataLayer = window.dataLayer || [];
function gtag(){dataLayer.push(arguments);}
gtag('js', new Date());
window.gtag('config', 'UA-160375581-4', {
send_page_view: false,
});
window.gtag('set', { referrer: 'https://child.com' });
</script>