How to remove specific categories from the breadcrumbs

#248176
  • Resolved Firas Seo
    Rank Math free

    Hello,

    I want to remove a specific set of categories from the breadcrumbs.
    For example if I have this hierarchy:

    Homepage > Home Improvement > Tools > Product Guide

    I want to remove “Home Improvement” so the breadcrumbs would look like this

    Homepage > Tools > Product Guide

    How can I do that? (I know how to code in php, so if there’s anything I can do in functions.php it’s not a problem)

Viewing 5 replies - 1 through 5 (of 5 total)
  • Hello,

    Thank you for contacting Rank Math and bringing your concern to our attention.

    From your breadcrumbs structure, it seems that Home Improvement
    is a parent category of Tools. Could you please confirm?

    If so, then you can disable this option in Rank Math > General Settings > Breadcrumbs
    Show Ancestor

    Here’s a link for more information:
    https://rankmath.com/kb/general-settings/#show-category

    I hope that helps.

    Thank you, and please don’t hesitate to contact us anytime if you need further assistance with anything else.

    Yes, but in my case there might be many child categories. Here is a more representative example:

    from Homepage > Home Improvement > Tools > Electric Tools > Product Guide
    to Homepage > Tools > Electric Tools > Product Guide

    or

    from Homepage > Cars > Berlines > Mercedes > Car Guide
    to Homepage > Cars > Berlines > Car Guide

    Hello,

    You can modify and use the following filter in your theme’s functions.php file to customize the breadcrumbs: https://rankmath.com/kb/filters-hooks-api-developer/#change-remove-breadcrumb-items

    Hope this helps. Let us know if you need any further assistance.

    Thanks.

    Excellent!
    Thank you

    Tammy
    Rank Math business

    Hello,

    We are super happy that this resolved your issue. If you have any other questions in the future, know that we are here to help you.

    If you don’t mind me asking, could you please leave us a review (if you haven’t already) on https://wordpress.org/support/plugin/seo-by-rank-math/reviews/#new-post about your overall experience with Rank Math? We appreciate your time and patience.

    If you do have another question in the future, please feel free to create a new forum topic, and it will be our pleasure to assist you again.

    Thank you.

Viewing 5 replies - 1 through 5 (of 5 total)

You must be logged in to reply to this ticket.