Install
This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.
Install straight from GitHub with WP-CLI:
wp plugin install https://github.com/dackzui/url-masker/archive/refs/heads/main.zipURL Masker Plugin
Create and manage masked redirect URLs to hide your destination links.
Overview
This plugin adds a "Masked URLs" custom post type to WordPress, allowing you to create clean redirect URLs that mask your actual destination. Perfect for affiliate links, tracking, or just keeping your URLs clean!
Features
- ✅ Custom Post Type - Manage masked URLs like regular posts
- ✅ Clean URLs - Format:
/go/your-custom-slug - ✅ Click Tracking - Built-in click counter for each URL
- ✅ Easy Management - Full WordPress admin interface
- ✅ One-Click Copy - Copy masked URLs to clipboard
- ✅ Shortcode Support - Insert masked links easily
- ✅ Custom Slugs - Use any slug you want (e.g.,
/go/amazon-deal)
Installation
- Upload the
url-maskerfolder to/wp-content/plugins/ - Activate through the 'Plugins' menu in WordPress
- You'll see a new "Masked URLs" menu item
How to Use
Creating a Masked URL
- Go to Masked URLs → Add New
- Enter a slug (title) - this will be your URL path (e.g., "amazon-deal")
- Enter the Destination URL - where people will be redirected
- Click Publish
- Your masked URL is created:
https://yoursite.com/go/amazon-deal
Example
Slug: amazon-deal
Destination: https://www.amazon.com/dp/B08XYZ?tag=youraffid-20&ref=xyz123
Result: https://yoursite.com/go/amazon-deal
When someone visits /go/amazon-deal, they're redirected to your Amazon link!
Managing Masked URLs
Go to Masked URLs to see all your masked links:
- View all masked URLs in one place
- See click counts
- Copy masked URLs
- Test redirects
- Edit or delete URLs
Using in Posts
Method 1: Direct Link
<a href="https://yoursite.com/go/amazon-deal">Check out this deal!</a>
Method 2: Shortcode
[mask slug="amazon-deal" text="Click Here"]
Or with custom content:
[mask slug="amazon-deal"]Check this out![/mask]
With custom CSS class:
[mask slug="amazon-deal" text="Buy Now" class="button"]
Features Explained
Custom Slugs
Unlike random codes, you get to choose memorable slugs:
/go/youtube-tutorial/go/affiliate-product/go/download-ebook
Click Tracking
Every masked URL tracks:
- Total number of clicks
- Last clicked date/time
- Reset button to start fresh
URL Management
- Copy Button - One-click copy to clipboard
- Test Button - Opens the redirect in a new tab
- Edit - Change destination anytime
- Delete - Remove old URLs
Statistics
Each masked URL shows:
- Large click counter
- Last clicked timestamp
- Reset option
Admin Interface
Edit Screen
- Title field = Your custom slug
- Destination URL = Where to redirect
- Your Masked URL = Copy-ready final URL
- Statistics = Click count and last clicked
List View
Columns show:
- Slug
- Masked URL (with copy/test buttons)
- Destination URL
- Click count
- Date created
Use Cases
Affiliate Marketing
Hide long affiliate URLs with tracking parameters:
Before: https://amazon.com/dp/B08...?tag=xyz&ref=abc123
After: https://yoursite.com/go/product-name
Link Management
Update destination without changing your content:
- Change the destination URL in admin
- All existing links automatically point to new destination
Clean Links
Make URLs memorable and professional:
yoursite.com/go/free-ebook
yoursite.com/go/webinar
yoursite.com/go/signup
Click Tracking
Monitor which links are popular:
- See click counts in admin
- Identify most effective links
- Track campaign performance
Technical Details
URL Format
Masked URLs use: https://yoursite.com/go/[SLUG]
Redirect Type
301 (Permanent Redirect) for SEO benefits
Post Type
- Slug:
masked_url - Public: No (not visible on frontend)
- Show in Admin: Yes
- Supports: Title only
Meta Fields
_destination_url- The target URL_click_count- Number of clicks_last_clicked- Unix timestamp of last click
Shortcode Reference
[mask slug="your-slug"]
[mask slug="your-slug" text="Click Here"]
[mask slug="your-slug" class="button"]
[mask slug="your-slug"]Custom Text[/mask]
Parameters:
slug(required) - The masked URL slugtext(optional) - Link text (default: "Click here")class(optional) - CSS class for styling
Best Practices
Slug Naming
- Use descriptive, memorable slugs
- Keep them short and simple
- Use hyphens for spaces
- Avoid special characters
Security
- Only share masked URLs, not destinations
- Regularly audit your masked URLs
- Delete unused URLs
Performance
- Minimal overhead (single database query)
- Efficient redirect handling
- No caching issues
Requirements
- WordPress 5.0+
- PHP 7.2+
FAQ
Q: Can I change the slug after creating it?
A: Yes, edit the masked URL and change the title. The old slug will stop working.
Q: What happens if someone visits a deleted masked URL?
A: They'll see a 404 error page.
Q: Can I use the same destination for multiple masked URLs?
A: Yes! Create multiple masked URLs pointing to the same destination with different slugs.
Q: Will this affect SEO?
A: No, we use 301 redirects which are SEO-friendly.
Q: Can I export click statistics?
A: Click data is stored in post meta, accessible via standard WordPress tools.
Q: What's the /go/ prefix for?
A: It's a common convention for redirect links. It keeps them organized and easy to recognize.
Troubleshooting
Issue: 404 on masked URLs
- Solution: Go to Settings → Permalinks and click "Save Changes" to flush rewrite rules
Issue: Slug already exists
- Solution: Choose a different slug (WordPress will warn you)
Issue: Redirect not working
- Solution: Make sure destination URL includes http:// or https://
Support
For issues or questions, contact the plugin author.
License
GPL v2 or later
Changelog
1.0.0
- Initial release
- Custom post type for masked URLs
- Click tracking
- Admin interface
- Shortcode support
- Copy to clipboard functionality