One of the features of WordPress is the author pages, which show information about the author of a post or page, including their name, bio, and other details.

While author pages can be useful in some cases, there may be situations where website owners want to disable them. In this article, we will discuss how to disable author pages in WordPress.

Why Disable Author Pages in WordPress

There are several reasons why website owners might want to disable author pages in WordPress. Disabling author pages can help streamline your website and make it easier for users to navigate. Here are some of the most common:

1. No need for Author Archive: If your website is managed by a single author or you don’t use WordPress as a multi-author platform, then there is no need for author archive pages.

2. Privacy Issues: Some authors might not want to reveal their personal information, such as their name or bio, on the website. Disabling author pages can help protect their privacy and prevent unwanted attention.

3. Low-Quality Content: In some cases, author pages can become cluttered with low-quality or outdated content. This can negatively impact your website’s overall user experience and search engine rankings.

4. Reducing Clutter: If a website has multiple authors, their author pages can clutter up the site and make it harder to navigate.

5. SEO: Author pages can also create duplicate content, which can be detrimental to SEO.

6. Focusing on the Content: In some cases, website owners may want to focus solely on the content of their site, rather than on the authors.

7. Site Speed: Large websites with many authors can result in a large number of author pages. These pages can slow down your website’s loading time, which can negatively impact user experience and SEO.

Overall, disabling author pages in WordPress can be a helpful way to improve website organization, privacy, content quality, and site speed also.

How to Disable Author Pages in WordPress

There are many ways to disable author pages in WordPress. Here are two of the most popular methods:

Method 1: Using a Plugin

One of the easiest ways to disable author pages in WordPress is to use a plugin. There are several plugins available that can help you achieve this, including the popular Yoast SEO plugin.

The Yoast SEO plugin is a powerful WordPress tool that can improve your website’s performance on search engines like Google, Yahoo. With this plugin, you can easily optimize your content for SEO and readability, ensuring that your website is of the highest quality. In this article, we’ll dive into how to disable author pages in WordPress using this plugin.

To disable author pages using Yoast SEO, follow these steps:

First Install and activate Yoast SEO.

Activation of the Yoast SEO plugin in the back-end of WordPress.

Then go to the Yoast SEO settings page and click on the Advanced tab. Here scroll down to the Author archives section.

The "Author archives" settings page of the Yoast SEO plugin for WordPress.

To conclude toggle the Enable author archive switch to the Disabled position and click on the Save Changes button.

The "Enable author archives" toggle has been disabled.

Disabling this will redirect the author archive to your site’s homepage.

Note: If you’re running a one author blog, the author archive (e.g. https://example.com/author/example/) will be exactly the same as your homepage. This is what’s called a duplicate content problem. If this is the case on your site, you can choose to either disable it (which makes it redirect to the homepage), or prevent it from showing up in search results.

Method 2: Using Code

Another way to disable author pages in WordPress is to use code. This method involves editing your site’s functions.php file, so it’s essential to back up your site before making any changes.

Here’s the code you’ll need to add to your functions.php file: You can do this by using template_redirect hook. See below the code example.

function rn_author_page_redirect() {
    if ( is_author() ) {
        wp_redirect( home_url() );
    }
}
add_action( 'template_redirect', 'rn_author_page_redirect' );

To disable the author page from WordPress and redirect to a 404 error page, simply copy and paste the following code into your functions.php file:

// Redirect Author Page to 404 
function rn_redirect_author_page() {
  global $wp_query;

  if ( is_author() ) {
    // Redirect to 404 error page 
    $wp_query->set_404();
    status_header(404);
  }
}
add_action( 'template_redirect', rn_redirect_author_page);

Conclusion

Disabling author pages in WordPress can be a useful way to protect privacy, reduce clutter, and improve SEO.

Whether you choose to use a plugin, code, or a custom page template, the process is straightforward and can be done in just a few steps. Just remember to back up your site before making any changes, so you can easily restore it if something goes wrong.