Getting Rid of Random Characters Appended to the URLs of Your WordPress Posts

Earlier today I noticed that among the WordPress blogs I run, Technical Blogging was the only one that generated a random string of characters appended to the permalinks of my posts. It looked something like this:

http://technicalblogging.com/a-new-blog-a-new-adventure/#.Tu9uCXN5vmM

My first assumption was that this was some sort of hash used by the WP Super Cache plugin, but even disabling that didn’t get rid of the issue. After investigating the code a bit, I was able to track the issue to a window.location.hash call in a JavaScript file that’s used by the Add This plugin.

Comparing the Add This settings of my various blogs, it immediately became clear that this annoyance was caused by having Track address bar shares checked. Unchecking that option got rid of the extra #. hash string.

Here are the full Add This settings I now use for this blog:

Add This settings

This enables Facebook, Twitter, Google+ counters within posts and pages, but not on the homepage or on other archives/categories.

Should you be experiencing this same problem, unchecking that particular setting, as you can see here, is all you need to do to remedy the issue.

If you enjoyed this article, don't forget to subscribe via email or RSS feed.
About Antonio Cangiano

Antonio Cangiano is a Software Developer and Technical Evangelist for IBM, as well as a web entrepreneur, serial blogger, and published author. He makes thousands of dollars blogging in his spare time about technical topics. He recently authored a definitive blogging book published by The Pragmatic Bookshelf, and launched a new blog called Technical Blogging.

Comments

  1. I too noticed this around the same time. The problem occurs across browsers and websites. I never would have associated it to my WordPress Blog. I’ll give this a shot and see what happens. — thanks

  2. thanks for the info, got the same issue too!

  3. thanks, for the info, because I have problem such. :).

  4. Thanks for the info. Your Add This settings fixed the problem.

  5. Antonio,

    I read this post with fascination, as I am suddenly plagued with 90% of my blog’s URLS not linking properly. All get 404’s.
    I had noticed recently that all my URLs had the /#.(characters) appended after the URL.
    I didn’t know why, concluding it has something to do with tracking. Boy, was I mad when I discovered my links are all broken.

    I tried unchecking that setting in AddThis, refreshing, emptying cache, etc, but the issue persists, Also tried deleting my Google Analyitics ID from AddThis settings, as that was mentioned in another post on this same issue.

    Can you possibly check my blog and see what might still be causing this maddening issue?

    Im getting emails about it, and I’m stumped!

    thanks a TON!

    David Julian

    • Hi Dave,

      my money would actually be on your permalink structure or web server configuration. I’d check that everything is correct under Settings -> Permalinks. Ensure also that your .htacess file matches what you see on that page.

  6. I was about to post this in Blogger Help. But you solved it so easily. Can anyone tell me, if it affects SEO or Google analytics stats??

  7. Thankyou for your post. Initially I thought my site was hacked, but reading your post saved my day.

  8. Thanks for posting this! It was driving me crazy trying to figure out where the extra URL text was coming from. This was the only site I found on the topic.

  9. hear hear — thank you for sharing and saving the sanity of many fellow WP users!

  10. I just had a client that was experiencing a variation on this AddThis problem. They had installed a widget manually on their site and used the script option

    I changed that from True to false

    That solved the problem and removed the odd tracking code at the end of the url.

    Thanks for the heads up!

  11. I got planning to publish this specific inside Doodlekit Aid. However you resolved that thus effortlessly. Can anyone show me, whether it influences SEARCH ENGINE OPTIMISATION or perhaps Yahoo and google statistics numbers??

  12. Kaydian Design says:

    Very grateful. Thank you.

  13. One unticked box ( address bar shares: ) solved the issue. So damn simple :D
    However, you’ve made it simple with your blog post.
    Thank you very much.

Comment Policy: We greatly appreciate your comments and thoughts. To keep things nice and friendly, comments are moderated and will be approved shortly after you submit them. Please use your name or handle to comment, and not that of your company or website.


Speak Your Mind

*

Current ye@r *