• Please complete the contact form below with details about your inquiry and I'll get back to you as soon as possible.

  • This field is for validation purposes and should be left unchanged.

How to disable taxonomy feed links in WordPress

If you’d like to disable feed links for a custom taxonomy in WordPress, you need to remove the action hook that adds it, like this:

add_action( 'wp_head', function() {
    if(is_tax('my_taxonomy_slug')) {
        remove_action( 'wp_head', 'feed_links_extra', 3 );
    }
}, 2 ); //important to have this priority less than the priority when the 'feed_link_extra' hook is executed

And now the feed links should not be displayed anymore inside the head tag.

Leave a Reply

Your email address will not be published. Required fields are marked *