How to Set Up Google Analytics on Joomla website
Google Analytics is a powerful tool for measuring your website's performance. In this tutorial, I'll explain how to add Google Analytics to Joomla website, it's easy.
1. Get a Google Analytics Tracking Code
There are many articles that describe in detail how to get the tracking code. You can read this article from W3schools.
2. Set Default Editor to None
Normally, editors block any script before saving, so you should not use editors but convert it to a regular text area. Go to System > Global Configuration > Default Editor : None.
Additionally, you also need to make sure you have permission to use the "script" tag. In System Configuration, go to the "Text Filters" tab, set "No Filtering" for the "Super User" user group.

3. Create a Custom module
This module is where you insert the code snippet from Google Analytics. Go to System > Site Modules > New > Custom

Copy the code from Google Analytics into this module. Other parameters are as follows:
- Title: No
- Position: Footer
- Status: Published
- Module Assignment: On all pages
- Advanced > Module Style : None

Save this module and check the result. Good luck!
1. The "radio buttons" extra field doesn't transfer the values in the additional field, e.g., "yes" or "no," and only enters certain values into the #__fields_values database.
2. The "textarea" extra field with the "Use editor" option checked converts to "textarea" when it should be "editor."
3. In K2, the extra field group is assigned in the category. In Joomla Articles, the category is assigned in the extra field. It would be nice if this were automatically completed. A checkbox could be added if someone doesn't want this option.