Try ERPNext Buy Support Partners Foundation

Add Google Analytics, URL not found

Hi everyone,

I am trying to add Google Analytics code into “HTLM Header, ROBOTS AND REDIRECTS” section, but it doesn’t work. From browser console, i see it’s append the url of my site and google url site which is “https://www.googletagmanager.com/gtag/js?id=xxxxxxxx

In addition, i tried to input the ID into “INTERGRATIONS” but it doesn’t show in website source code.

Could you please show me how to fix it?
Thank you.

I have Google Tag manager since many years in the HTLM Header, ROBOTS AND REDIRECTS” section and works perfect.

I use the ErpNext hosted by Frappe

Don’t know what’s wrong with my site, from the console it shows like this:

https://mysite.com/https://www.googletagmanager.com/gtag/js?id=G-XXXXXXXX

As result, it’s not loaded properly.

please refer the attached screenshot of this error.

Thank you.

This usually happens when the url is entered incorrectly. Eg: you don’t and an http or https ahead of the url so the system appends the entire site and treats the address you added as a relative one.

Can you share how the gtag has been entered? You can block/cancel out any sensitive information from the screenshot.

thanks @kennethsequeira for your reply.
Please see attached screenshot below for my gtag setting.

Thank you.

Do you have any idea how to correct this?
Thank you.