A friend of mine, Mike ( who blogs about old cameras amongst other things over at https://www.sgtberbatov.com/ ) came to me with an annoying niggle about his WordPress blog.
He showed me that his author pages had been indexed by Google, and if he did a site:sgtberbatov.com, it was listing all his author profiles in the search engine results, along with his admin username. I had a think about this and after a quick scan on WordPress.org, I realised there was no plugin available that allows you to hide your author URLs. The closest I found was something that allows you to edit your author URL slug. So…
…I built a plugin
Its called WP Custom Author URL, and in the process of building it, I expanded its feature set a bit. As of version 1.0.0, this is what it does:
- It allows you to customise an author’s profile URL, to whatever you like. I say author, but any user level works fine. This is handy for guest bloggers who want to link to their own social media profile instead of a plain old WordPress author page.
- It redirects their old author URL eg. /author/billybob to the same URL that you defined.
- It gives the admin the ability to override the above using a global setting.
I’ll run through all the settings here, so you can get up & running with it right away.
Once you have actually installed the plugin, you’ll find there are two lots of settings. One global section which sits under the standard ‘Settings’ menu, and then a user-specific section, on their actual User Profile page.
Set a custom URL for a single author:
If you want to edit your own author URL, go to Users > Your Profile, otherwise, if you’re an admin, find the profile page you want from Users > All Users
Scroll down to the plugin settings, they’re at the bottom right before the blue save button:
The settings are pretty basic, but you can put your own Twitter, Instagram, or whatever link you like here. The checkbox will toggle its active state.
On the front-end of the site, two things will now have changed.
Your author link will now be customised:
If you try to directly access your author URL, it will redirect:
Set a global URL for all authors:
Your other option is to set a global ‘fallback’ URL which can either apply to all authors, regardless of whether or not they have their own URLs set, or just to authors without a custom URL:
Note the 2 checkboxes in the image above – The ‘Redirect All Author URLs?’ checkbox toggles the active state, and the ‘Override Individual Authors?’ checkbox allows you to force your global setting to take priority.
Advantages of the plugin
- You are no longer restricted to the standard Author page. You could link to your about page, or anything you fancy.
- A guest author can ensure that their author name links directly to their own Twitter or even their own blog.
- A security conscious blog owner no longer has to hide their author pages from search engines to avoid their admin username being listed in the SERPs. They simply set a global custom override.
I hope you find this plugin useful, Mike said he does. If it solved a problem for you too, that’s fantastic, so please let me know. Also, the WordPress.org search results show plugins with more reviews first, so if you want to thank me, please post a quick review on the plugin page.
Feedback for the plugin can either be left in the comments below, or you can add a support request or suggestion on the plugin page itself.
Leave a Reply