Description
B2Apps UTM Cleaner keeps your WordPress URLs clean, shareable, and free of noisy tracking parameters — with zero bloat and zero external requests.
Key Features
- Canonical URL Cleaning: Removes tracking parameters from WordPress canonical URLs (
get_canonical_url) to help prevent duplicate-URL indexing. - Outbound Link Cleaning: Strips tracking parameters (
utm_*,fbclid,gclid,mc_cid,mc_eid,msclkid,yclid,igshid) from external links in post content while preserving legitimate query arguments and anchor fragments. - Redirect Cleaning: Filters
wp_redirectdestinations so redirects do not forward unwanted tracking tokens. - Copy-Clean-Link Helper & Shortcode: Provides a lightweight
[cleanlink_copy]shortcode and optionalhistory.replaceStatebrowser address-bar cleaner. - Domain Allowlist & Live Tester: Exclude specific outbound domains and preview how any URL is cleaned directly under Settings -> B2Apps UTM Cleaner.
Privacy
B2Apps UTM Cleaner runs 100% locally on your WordPress site and in the visitor’s browser. It does not make external API calls, load third-party scripts, or collect any telemetry.
Installation
- Upload the plugin folder to
/wp-content/plugins/, or install the plugin ZIP file via Plugins -> Add New -> Upload Plugin. - Activate the plugin through the Plugins menu in WordPress.
- Go to Settings -> B2Apps UTM Cleaner to review or customize stripped parameters and excluded domains.
- Optional: Add
[cleanlink_copy label="Copy Clean Link"]to any post or template.
FAQ
Does B2Apps UTM Cleaner remove legitimate query parameters like ?page=2 or ?s=search?
No. B2Apps UTM Cleaner only removes query parameters that match your configured tracking patterns (such as utm_*, fbclid, gclid, and mc_cid). All other query arguments and #fragment anchors are preserved.
Can I keep tracking parameters for specific partner or affiliate domains?
Yes. Add those domains (one per line) to Excluded Outbound Domains under Settings -> B2Apps UTM Cleaner.
Does B2Apps UTM Cleaner phone home or send URLs to an external service?
No. Everything runs locally in PHP and vanilla JavaScript.
Changelog
1.0.0
- Initial release: canonical URL stripping, outbound content link stripping, redirect filtering, copy-clean-link shortcode/helper, and Settings -> B2Apps UTM Cleaner admin page with live URL tester.
