How to stop self ping from your own post

A blog pings all the pinging service that you have updated. Whenever you link your post to one of your own old posts, it will automatically send a pingback or self-ping. Some people find this feature useful. Others find it very annoying.  Let’s see how to stop self ping of your own post.

How to stop self ping from your own post

How to stop self ping from your own post
  • Save
How to stop self ping from your own post

Before we see the methods stop self-ping, let us see how self-ping was created. When your site self-pings with the internal link on your post, it creates a comment with the link to your own post. Below image shows the pingback comment on your dashboard

self-ping-on-site
  • Save
Self ping on site
How to stop self ping from your own post 1
  • Save

The above image shows the pingback or self ping created on the blog.

Methods to stop self ping

It is not possible to disable or stop self ping from the dashboard of your WordPress. There are two methods to stop the self-pinging of your post. The first method is with the help of codes and the second method is with the help of the plugin.

How to stop self ping in functions.php file

This is one of the easiest methods to stop self ping if you are well versed with the coding. You just need to add the code to your website theme.

Follow the steps below:

1. Login to your site.
2. From the dashboard, click on appearance and select editor.
3. Click on functions.php on the right hand side.
4. Add the code below to your theme’s functions.php file and click on apply at the bottom.

//remove pings to self
function no_self_ping( &$links ) {
$home = get_option( ‘home’ );
foreach ( $links as $l => $link )
if ( 0 === strpos( $link, $home ) )
unset($links[$l]);
}
add_action( ‘pre_ping’, ‘no_self_ping’ );

adding-code-on-website-to-stop-selfping
  • Save
Adding code on a website to stop self ping

If you are not willing to play with the code or afraid to edit your theme’s code, you can just follow the second method.

Disable self-ping with No self Ping plugin

You can just download the No-Self Ping plugin and install it to stop self-pinging off your post. This plugin does the same job as the code mentioned above.

Advantages

No need to touch your theme’s coding.

Disadvantages

Additional plugin to your site.

Conclusion

You can use either the first method or install the plugin to stop the self-ping back of your blog. Some people wish to use only a limited number of plugins. For those, the first method is the best solution.

How to stop self ping from your own post
  • Save

Blogger and Entrepreneur. You can follow him on Twitter. At Onlinedecoded.com, he writes mostly about Blogging and Technology Tips

4 thoughts on “How to stop self ping from your own post”

  1. Hi Umapathy,
    First time I visit on your blog and you solve my one big problem. Self pinging a headache for me, I can’t find any perfect solution for it, to stop it.
    Going to implement this tip on my blog.
    Hope this one going to be helpful for me.
    BTW thanks for this post.
    Hope you have a great weekend.
    -Hamim

    Reply
  2. Hi Hamim,

    Warm welcome to you. Self pinging was a problem to me once and found the solution after much research. Thought fellow bloggers would benefit if I could share the information.

    I am glad to know you were able to find the solution to your problem on this post.

    Thank you for visiting and sharing your experience.

    Have a great week end ahead 🙂

    ~Umapathy

    Reply

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.

96 Shares
96 Shares
Share via
Copy link