Simple, lightweight solution for inserting your Google Analytics Universal tracking code.
As of April 2026, Tracking Code for Google Analytics is a WordPress google plugin with 100 active installations and a 0/5 rating0. It has been downloaded 5.3K+ times in total. Requires WordPress 5.0+ and PHP 7.2+. Available on WordPress.org since 2020. Last updated 1 year ago — may have compatibility concerns. Top alternative: Site Kit by Google – Analytics, Search….
Tracking Code For Google Analytics is a simple, lightweight WordPress plugin for inserting your Google Analytics Universal Analytics tracking code. The plugin does one thing and one thing only; prints the standard Google Analytics tacking script to the <head> of your website. To insert your tracking ID, navigate to Settings > General and then scroll to the bottom of the page.
composer require claytoncollie/tracking-code-for-google-analytics
If you want to set the tracking ID without using the wp-admin user interface, use the filter below.
add_filter(
'tracking_code_for_google_analytics_id',
/**
* Set Google Analytics tracking ID.
*
* @param string $tracking_id Tracking ID.
*
* @return string
*/
function ( string $trackin…| WordPress | 5.0+ requiredTested up to 6.6.0 |
| PHP | 7.2+ required |
Plugin data sourced from WordPress.org. Analysis and metrics by PluginSift.