Remove Post Title From Yoast SEO Plugin Breadcrumb

How to Remove Post Title From Yoast SEO Plugin Breadcrumb

WordPress SEO by Yoast is undoubtedly powerful seo plugin for wordpress websites and it has many built in features such as XML sitemaps, Breadcrumb navigation, file editor and still more. But Yoast Breadcrumb navigation does not have enough features and options to control them which results breadcrumb navigation looks ugly (in my perspective) and it shows duplicate post title trailing with breadcrumb navigation.

There is a post title already there in native wordpress themes and again showing the same variable with Yoast breadcrumb navigation not quite good. Sometimes, if the post title gets longer, it wraps down to second line and looks fishy. When i search for the solution via google, unfortunately there is no solution which works successfully. So, i did request my friend Mr.Kannan (CEO of corel web designs) to find the solution for this issue. After some in-depth analysis (2 hours+) he added a new function to get rid of post title trailing with breadcrumb navigation without hacking the original WordPress SEO plugin core files. It works!

Here i am sharing the code with you who is interested to get rid of post title trailing from the Yoast SEO plugin breadcrumb navigation. Simply add the below code in your functions.php file (probably in your wordpress child theme) and make the necessary changes in your single.php as well.

function adjust_single_breadcrumb( $link_output) {
	if(strpos( $link_output, 'breadcrumb_last' ) !== false ) {
		$link_output = '';
   	return $link_output;
add_filter('wpseo_breadcrumb_single_link', 'adjust_single_breadcrumb' );

If you found any difficulties to apply this technique, post your comment below using the comment form. Your valuable suggestions are always welcome.


    • Hello andrew

      Final breadcrumb? Which one you are referring about? Did you refer some live websites who have this feature?

  • I have tried several codes but since the last SEO YOAST update (now is march 2015), this is the only php snippet that works.
    Thank you very much.

  • Thank you so much, nothing else has worked for the new update ( March 2015 ), I already have it under another breadcrumb function so – took out the top line and it works perfectly.

  • Hello, I’m new to coding so please bare with me! Would you mind telling me where the code goes in the function file and the single file? Could you please explain how you install this line of code in the function and single files? Where does it goes?

    • Hi alaster

      If you already installed Yoast SEO plugin and included the snippet to render the breadcrumbs in single.php file, then simply add the above code in functions.php file (Use child theme always)

  • Funciona muy bien Gracias, Selvam, the code is placed at the end of functions.php file and before these characters (?>)

Leave a Comment

All about WordPress / Joomla / Drupal CMS & HTML Templates

All about WordPress / Joomla / Drupal CMS & HTML Templates

Be the first person to get notified about latest and greatest premium / free WordPress themes reviews, WordPress tips, Joomla templates, admin & frontend HTML templates and lot more.

You have Successfully Subscribed!