Title: blog_redirect_404
Published: April 25, 2014
Last modified: April 28, 2025

---

# apply_filters( ‘blog_redirect_404’, string $no_blog_redirect )

## In this article

 * [Description](https://developer.wordpress.org/reference/hooks/blog_redirect_404/?output_format=md#description)
 * [Parameters](https://developer.wordpress.org/reference/hooks/blog_redirect_404/?output_format=md#parameters)
 * [Source](https://developer.wordpress.org/reference/hooks/blog_redirect_404/?output_format=md#source)
 * [Related](https://developer.wordpress.org/reference/hooks/blog_redirect_404/?output_format=md#related)
 * [Changelog](https://developer.wordpress.org/reference/hooks/blog_redirect_404/?output_format=md#changelog)

[ Back to top](https://developer.wordpress.org/reference/hooks/blog_redirect_404/?output_format=md#wp--skip-link--target)

Filters the redirect URL for 404s on the main site.

## 󠀁[Description](https://developer.wordpress.org/reference/hooks/blog_redirect_404/?output_format=md#description)󠁿

The filter is only evaluated if the NOBLOGREDIRECT constant is defined.

## 󠀁[Parameters](https://developer.wordpress.org/reference/hooks/blog_redirect_404/?output_format=md#parameters)󠁿

 `$no_blog_redirect`string

The redirect URL defined in NOBLOGREDIRECT.

## 󠀁[Source](https://developer.wordpress.org/reference/hooks/blog_redirect_404/?output_format=md#source)󠁿

    ```php
    $destination = apply_filters( 'blog_redirect_404', NOBLOGREDIRECT );
    ```

[View all references](https://developer.wordpress.org/reference/files/wp-includes/ms-functions.php/)
[View on Trac](https://core.trac.wordpress.org/browser/tags/6.9.4/src/wp-includes/ms-functions.php#L2200)
[View on GitHub](https://github.com/WordPress/wordpress-develop/blob/6.9.4/src/wp-includes/ms-functions.php#L2200-L2200)

## 󠀁[Related](https://developer.wordpress.org/reference/hooks/blog_redirect_404/?output_format=md#related)󠁿

| Used by | Description | 
| [maybe_redirect_404()](https://developer.wordpress.org/reference/functions/maybe_redirect_404/)`wp-includes/ms-functions.php` |

Corrects 404 redirects when NOBLOGREDIRECT is defined.

  |

## 󠀁[Changelog](https://developer.wordpress.org/reference/hooks/blog_redirect_404/?output_format=md#changelog)󠁿

| Version | Description | 
| [3.0.0](https://developer.wordpress.org/reference/since/3.0.0/) | Introduced. |

## User Contributed Notes

You must [log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fdeveloper.wordpress.org%2Freference%2Fhooks%2Fblog_redirect_404%2F)
before being able to contribute a note or feedback.