How to fix Yoast SEO Breadcrumb http Problem?

June 26, 2020 0 comments
default placeholder

Breadcrumbs are an important part of almost every good website. These little navigational aids don’t just tell people where they are on your site, but they also help Google work out how your site is structured. That’s why it makes a lot of sense to add these helpful little pointers. Let’s take a look at how breadcrumb navigation works. – Yoast

Lots of people are asking questions about the Yoast SEO breadcrumb HTTP and HTTPS issues, WordPress Tickets, stackoverflow.com, and other support channels as well.  For this, I have composed a short and sweet code for this solution.

This solution is very simple and useful for every WordPress user whether you are developer, designers, or owners using Yoast SEO plugin.

What are breadcrumbs?
A breadcrumb is a small text path, often located at the top of a page indicating where the user is on the site. On yoast.com, for instance, the path to our Yoast SEO plugin page is Home > WordPress Plugins > Yoast SEO for WordPress. This breadcrumb trail immediately shows you where you are. Every step of that path is clickable, all the way back to the homepage.

But why is this navigational help called a breadcrumb? When Hansel and Gretel went into the woods, Hansel dropped pieces of bread onto the ground so they could find their way home if they got lost. These breadcrumbs eventually became the model for the ones we see on websites these days.

Here is the quick and smart solution for your HTTP issues.

  1. Copy the following code
    add_filter( 'wpseo_breadcrumb_output', 'custom_wpseo_breadcrumb_output' );
    function custom_wpseo_breadcrumb_output( $output ){
    if( is_page() ){
    $from = 'http://'; // EDIT this to your needs
    $to = 'https://';
    $output = str_replace( $from, $to, $output );
    }
    return $output;
    }
  2. Login to WP Admin Dashboard
  3. Click on Appearance > Editor
  4. Open functions.php(make sure its a child theme).
  5. Paste the code and save it.
  6. Congratulations, it must be working.

Have a Wonderful Day.

Ashok kuikel

Ashok Kuikel is DevOps Engineer(Cloud Computing and Cyber Security), Entrepreneur working on Socio-Economic Development via Technology

He has been actively contributing as Joint Secretary of Federation of Computer Association of Nepal Kavre Chapter. Beside that, he is an official Global Peace Ambassador for Global Peace Chain, Nepal Chapter and Member of Internet Society, Nepal Chapter.

Above all, he enjoys learning about new trends and technologies and loves to share innovative ideas to contribute for the growth of the industry.

You can follow me on Social Media, GitHub, and via my Blog Channels.

Leave a Reply

Articles and Tutorials

We love writing about WordPress and latest plugins tutorials, WooCommerce stats, and much more.