# Rank Math Breadcrumbs Without the Current Page

> Drops the last item (the page being viewed) from the Rank Math breadcrumb trail, leaving only the links that lead to it.

- Type: PHP
- Runs: Frontend only
- Category: [Plugin Integrations](https://wpide.com/library/category/integrations/)
- Tags: rank-math, breadcrumbs, navigation
- Author: WPIDE Team
- Installs: 0
- Updated: 2026-10-28
- Page: https://wpide.com/library/rankmath-breadcrumb-hide-current/

## Code

```php
add_filter( 'rank_math/frontend/breadcrumb/items', function ( $crumbs ) {
    if ( is_array( $crumbs ) && count( $crumbs ) > 1 && ! is_front_page() ) {
        array_pop( $crumbs );
    }

    return $crumbs;
} );
```

## Notes

Rank Math also has a "Hide Post Title" option for posts; this works on every page type.

## How to use it

Install the free WPIDE plugin (https://wordpress.org/plugins/wpide/), find "Rank Math Breadcrumbs Without the Current Page" in its snippet library and add it in one click; or create a new PHP snippet in WPIDE (or any code snippets plugin) and paste the code above. More snippets: https://wpide.com/library/
