If you need to change your WordPress permalinks for any reason, this post will walk you through the steps of changing the URLs, options to set up redirection so that you retain SEO rankings, and recover lost social share counts.
Earlier this year, I changed the permalinks of my WordPress.org blog to remove the year and the month such that:
would become http://gingerandscotch.com/chinese-grocery-stores-2/
That was the easy part. Just a simple change in WordPress settings.
Next came setting up redirects so that anyone who clicked on or typed the old URLs would automatically get redirected to the new URLs and any “google juice” associated with the old URL would get passed to the new ones. That was also fairly easy to setup with the help of a plugin.
I could have just left things at that but I wanted to preserve all my social share counts so that my posts weren’t showing a BIG FAT ZERO in the number of Facebook shares, Pinterest saves, and Stumbles. I found a plugin (paid) that claimed it could recover lost share counts: Social Warfare.
Social Warfare (affiliate link) is a powerful and highly customizable plugin that not only adds social share buttons to your WordPress site (previously I had been using Shareaholic) but also claims to recover your share counts when switching permalink structures or going from HTTP to HTTPS protocol. At the moment, it cannot recover share counts if you switch domains.
Below are the three main steps to change your permalinks, set up 301 redirects, and recover your share counts.
1) How to Change Your Blog’s Permalinks
Go to your go to your WordPress Settings -> Permalinks and select Post name:
WordPress will now automatically change all your permalinks in less than a second.
If you do nothing else at this point, when someone tries to visit a page with your old URL, they will land on a blank page or receive a “404 page error” and all the content indexed by search engines will be incorrect.
2) How to Set-up Redirects
To fix these broken links, you set up “301 redirects” to tell any browser that comes to your site, using your old permalink, what the new permalink is. It also lets search engines know that this is a permanent change and passes between 90-99% of link juice (ranking power) to the redirected page. To further understand redirects, click here.
If you are tech savvy, you can manually modify your site’s .htaccess file to set up all the 301 redirects. This page from YOAST will help you with the code.
An easier method is to let a plugin do the work. I chose the Redirection plugin (free) by John Godley.
I migrated from Blogger/Blogspot a long time ago (that meant my URLs contained “.html” at the end) so my permalink structure was http://gingerandscotch.com/year/month/postname.html. Here is the screenshot of my redirection settings:
Figuring out the “Source URL” gave me the biggest headache because it took me a while to figure out where to input the “.html” but it all made sense after I figured it out. The plugin author did provide some documentation but it wasn’t exactly user-friendly.
I’ll break down what my fields look like in the hopes that it may help you:
For Source URL, I entered: /(\d*)/(\d*)/(.*).html where (d*) indicates a number, and the (.*) a sequence of characters
For Target URL, I entered: /$3 which redirects by removing all the numbers (d*) and leaving just my the third string ($3) in my permalink and also exlcudes the .html
You do not need to enter your web site URL as the first backslash (/) accomplishes that.
So the old URL http://gingerandscotch.com/2011/03/example.html gets redirected to http://gingerandscotch.com/example.
Your source URL and target URL may differ depending on your original and new permalink structure.
Now that you have changed your permalinks, redirected the old links to your new ones, you can stop here or continue to the next and last step to recover your social share counts.
3) Recover Your Social Shares with Social Warfare Plugin
Social Warfare is a paid plugin that can help you recover your social share counts.
If you were using a social sharing plugin that displayed how many times your post was shared via Facebook, Twitter, Pinterest, and how many Stumbles, etc., you will notice that all your social share counts have reset to a big fat ZERO.
Because the social share counts are linked to a particular URL and once that URL changes, you reset the share counts.
It doesn’t matter which social sharing plugin you are using, your counts will reset because the statistics are not stored by the plugins but by each individual social media platform (Facebook, Pinterest, StumbleUpon, etc.).
So what can you do if Social Proof is important to you?
The easiest solution is to install a plugin called Social Warfare. This is a paid plugin and costs $24 a year but does have a 60-day money back guarantee. I don’t normally pay for plugins but I gave it a try since there seemed to be a slew of other cool features other than share recovery.
Here are my settings in the Share Recovery tab of the Social Warfare plugin:
For “Previous URL Format” I chose “Custom” and entered my old permalink structure which was /%year%/%monthnum%/%postname%.html.
If you used one of the standard WordPress permalinks, then just choose it from the drop-down options:
The plugin will now take the social share counts from your old URLs and combine them with new shares from your new URLs.
Other Nifty Features I Liked About Social Warfare:
Once you have installed the plugin you will see that there are A LOT of nifty functions other than Share Recovery like having Twitter share counts again! You won’t be able to recover previous Twitter counts because they are no longer stored anywhere but going forward, new tweets can be tracked. Although I don’t know if it is 100% accurate.
Other useful features:
- Frame Buster – some sites like Yummly and BlogHer display your blog post in their own custom frame so that their branding and logo is always visible. Frame buster gets rid of all that and directs viewers to your website instead.
- Fast Load Times (so it doesn’t bog down your website’s speed)
- Click to Tweet
- Customizable Tweets
- Analytics tracking
Things To Know Before Purchasing:
- Domain changes – Social Share Recovery doesn’t work if you’ve changed domains but does work of you change http/https protocol.
- Displayed counts are not in real-time – This is because Social Warfare caches the share counts and only refreshes every few hours to keep the plugin lightweight and not bog down your site speed. You can, however, force the counts to accurately show by going to the post editor and updating the post.
- Pinterest share button only displays ONE image – Just like when you click the Tweet button, a specific message is tweeted, the Pinterest button displays ONE specific image. According to the plugins co-founder, the reason behind this is to encourage the use of long pins. You can set this specific image within each post. If no image is set, then the Featured Image is selected. If no Featured Image is selected, then I believe it selects the first image within the post.
- Yearly Renewal – I asked the co-founder what would happen if I didn’t renew for the next year and the response was, “If a user does not renew their license the plugin will revert to basically just a set of buttons with none of the premium features (such as customization and styles) but they will not lose share counts.“
In summary, I’m happy that the plugin worked the way I hoped and although I had to email the developer a few times regarding some issues, the response time was fast and my questions were answered within a day or two.
If you are looking to recover your share counts, then definitely consider purchasing Social Warfare. I hope this tutorial was helpful – Please let me know if you have any comments, questions, or further tips by emailing me or leaving a comment below.
* * * * *
One final tip: if you use Yummly, you will need to “yum” all your recipes again and then email Yummly to have them combine your old yums with your new ones. I think it took Yummly about 2 weeks to sort this out for me.
One more final tip: Instead of waiting for Google to recrawl your site, you can manually submit a request to update your new URLs via this link.
Disclaimer: This post contains affiliate links where, at no additional cost to you, we receive a small commission when products are purchased through links on our blog.