Analytics Head
Analytics Head is a deliberately simple WordPress plugin for Google Analytics. No dashboards, no Google account connection, no feature creep — just the tracking code, placed exactly where you want it. Why use this plugin? Lightweight — a handful of options, minimal overhead, no external dependencies Easy — paste your GA4 Measurement ID (G-XXXXXXXXXX) and you are done Head placement by default — required for Google Search Console verification via Analytics Flexible — footer placement, role-based hiding, Consent Mode v2, optional Google Ads IDs Developer-friendly — filters and actions to customize output without forking the plugin Unlike heavyweight analytics suites, this plugin does one job well: inject the standard gtag.js snippet into your site. Features Google tag / GA4 Measurement ID support (GT-…, G-XXXXXXXXXX) Additional tracking IDs for separate destinations (e.g. Google Ads AW-) Legacy UA- ID acceptance (with admin notice to migrate) Code in by default (optional footer placement) Tracking never injected in wp-admin Hide tracking for administrators on the front end Hide tracking per user role Google Consent Mode v2 defaults (for GDPR / cookie plugins) Keep settings on uninstall (optional) Developer hooks and filters External services This plugin connects to Google Analytics (via Google Tag Manager / gtag.js) to provide website analytics. When: on public front-end page views only (never in the WordPress admin area), unless tracking is hidden for the current visitor by plugin settings What is sent: standard Google Analytics measurement data (for example page URL, referrer, browser/device information, and IP-derived location), processed by Google Who receives it: Google LLC / Google Analytics Terms of Service: https://marketingplatform.google.com/about/analytics/terms/us/ Privacy Policy: https://policies.google.com/privacy You are responsible for informing visitors (for example in your privacy policy) and, where required, obtaining consent. Suggested privacy policy text is also offered under Settings → Privacy when the plugin is active. Requirements WordPress 6.3 or later (compatible with WordPress 7+) PHP 7.4 or later Examples Filter tracking IDs add_filter( 'pp_google_analytics_head_tracking_ids', function( $ids ) { // Add a separate destination only — not a second ID for the same Google tag. $ids[] = 'AW-123456789'; return $ids; } ); Change Consent Mode defaults (PHP) add_filter( 'pp_google_analytics_head_consent_defaults', function( $defaults ) { $defaults['wait_for_update'] = 2000; $defaults['region'] = [ 'PL', 'DE', 'US-CA' ]; return $defaults; } ); Grant consent after the user accepts cookies (JavaScript) Call this from your consent plugin callback or custom banner “Accept” handler. Update all four types that this plugin sets to denied by default: gtag('consent', 'update', { analytics_storage: 'granted', ad_storage: 'granted', ad_user_data: 'granted', ad_personalization: 'granted' }); If you only want basic analytics (not ads), grant analytics and keep ads denied: gtag('consent', 'update', { analytics_storage: 'granted', ad_storage: 'denied', ad_user_data: 'denied', ad_personalization: 'denied' }); Modify the inline gtag config add_filter( 'pp_google_analytics_head_inline_script', function( $script, $ids ) { $script .= "gtag('event','page_view');"; return $script; }, 10, 2 );
Top keywords
- google19×3.97%
- analytics16×3.34%
- tracking8×1.67%
- consent7×1.46%
- google analytics7×1.46%
- ids7×1.46%
- ad6×1.25%
- defaults6×1.25%
- gtag6×1.25%
- 'granted'5×1.04%
- head5×1.04%
- privacy5×1.04%
Machete
Machete is a simple suite of tools that solves common WordPress annoyances using as few resources as possible. Machete doesn’t cover every single use case, but there is a huge amount of sites that would require less plugins if they used Machete. All Machete tools have two things in common: they solve problems faced by many web developers and they do it using as few server resources as possible. So far, Machete includes the following tools: WordPress Optimization WordPress places a lot of code inside the tag just to keep backward compatibility or to enable optional features. You can disable most of it and save some time from each page request while making your installation safer. Cookies & GDPR Warning We know you hate cookie warning bars. Well, this is the least hateable cookie bar you’ll find. It is really light, doesn’t affect your PageSpeed score and plays well with static cache plugins. Analytics and custom code You don’t need a zillion plugins to perform easy tasks like inserting a verification meta tag (Google Search Console, Bing, Pinterest), a json-ld snippet or a custom stylesheet (Google Fonts, Print Styles, accessibility tweaks…). The Google Analytics and Google Tag Manager tracking codes are PageSpeed optimized, GPDR friendly. Maintenance mode The maintenance mode that ships with WordPress is just a basic lock-down that is activated whenever you do a major update. With machete Maintenance Mode you can hide your unfinished page from visitors and search engines, give your clients a secure temporary access and lock your site without affecting your SEO. Post & Page cloner Adds a “duplicate” link to post, page and most post types lists. Also adds “copy to new draft” function to the post editor. Social Sharing Buttons Social sharing done the Machete way. The icons are made as a custom webfont embedded in a minified CSS file that only weighs 5.8KB. The sharing actions use each platform’s native share URL. WooCommerce Utils WooCommerce was designed to work for every possible use case, but that often leads to unexpected behavior. These simple fixes can improve the WooCommerce user experience by making it behave as clients expect.
Top keywords
- machete7×1.94%
- google4×1.11%
- page4×1.11%
- post4×1.11%