Resources     Blog  

  1. Home
  2. WordPress Tutorials
  3. How to Delete the Author Name in WordPress

How to Delete the Author Name in WordPress

Do you want to delete author names in WordPress? You may think this is quite hard because WordPress does not have a way to remove author names by default, but like most things in WordPress, this is accomplished with the use of plugins.

Just keep in mind that there are advantages and disadvantages to not having an author name appear on posts in WordPress.

Having an author allows you to show visitors that the person writing is experienced and credible. For example, does an article about computer operating systems written by no one look/sound better than one by Bill Gates?

Obviously, everyone doesn’t have the same experience as Bill Gates, but as long as your author has the experience and is knowledgeable, it is worth sharing his/her name with visitors. Today, I will demonstrate how to delete the author’s name in WordPress using two methods.

Why Delete the Author Name in WordPress

It’s pretty easy to see the advantages of displaying the WordPress author names, but there can be some disadvantages as well. For example, an author might get a negative image associated with their work when they are in support or against a controversial topic.

And this has only gotten worse as harassment on social media has, sadly, become more popular.

However, this isn’t just bad for the author, it can have a negative effect on your website. Unfortunately, internet users are very slow to forgive and forget, if that ever even happens. As a result, it may end up being better for your website if you remove the author’s name.

There is also the possibility that the author was removed from the website’s staff so it might be best to remove their name off of your website. A better method to avoid all of this is to either remove the author’s name entirely or only have a few set names that authors will write under.

This is very common and can save you quite a few headaches down the road.

How to Delete the Author Name in WordPress

Today, I will demonstrate how to delete author names in WordPress using two methods. The first method is very simple and will use the Hide/Remove Metadata plugin. This plugin allows WordPress to hide the author’s name on any kind of content.

The second method is much harder because you will have to manually remove the author using code. If you use the second method, I strongly recommend creating a backup in case anything goes wrong.

Method 1: Plugin

Start off by clicking on Plugins and selecting the Add New option on the left-hand admin panel.

Add New

Search for Hide/Remove Metadata in the available search box. This will pull up additional plugins that you may find helpful.

Hide/Remove Metadata

 

Scroll down until you find the Hide/Remove Metadata plugin and click the “Install Now” button. Activate the plugin for use.

Install Now

 

How to Delete Author Names

The plugin is extremely easy to use and only requires one step. However, I do want to make something very clear before moving forward. WordPress will always have an author assigned to every post.

This plugin cannot actually delete author names itself. Instead, you are simply hiding it from view.

On the left-hand admin panel click on the Hide/Remove Metadata option.

Hide/Remove Metadata

The plugin is broken up into two tabs, Dashboard, and Features. Luckily, the Features tab is just an explanation of each feature and you can read them at any time. Instead, what we are looking for is in the Dashboard tab.

Locate the Hide Author switch and click it. It will be green if it is enabled.

Hide Author

You may also want to hide the date when the article was published. After you are done in the settings, click on the “Save Changes” button to finish.

 

Save Changes

That’s it. If you go onto your website, the author will no longer be visible, congratulations.

Note: Depending on your theme, some words may remain like “written by” or “author” and there is no way to address this without customizing your theme. Each theme is unique, so you are going to need to search for your specific theme to find how to remove or hide those words.

Method 2: Coding

The next method will involve editing code and you should make a backup before beginning the process. You will also need access to your cPanel, which is provided by your web host when you create an account.

It is actually a little bit of a challenge to find the author information and it is quite different depending on the theme you have installed. So using my screenshots or code will not work if you are not using the same theme. If you are not comfortable with coding, I would recommend using the plugin method.

For reference, I am using the Twenty Seventeen theme, which is the default WordPress theme.

Inserting Code

Let’s start by logging into the cPanel and clicking on the File Manager option. The File Manager will allow you to access all of the files related to your website.

Click on the File Manager option.

You need to locate your theme’s functions.php file. Click on the public_html directory and click on the wp-content folder. Click on the themes folder and click on the folder of the theme you are currently using. Right-click on the functions.php file and select the Edit option.

Note: If you are not using the same theme, the information you are looking for may not be in the functions.php file. Instead, it may be located in the templates-tags.php file.

Select the "Edit" option.

A pop-up window will show up. This box will warn you to create a backup of your files before editing anything. This will ensure that you can revert your website back to the previous version if something goes wrong. Click on the “Edit” button. A new tab will open containing all of the code from the file.

You need to locate the following code:

function twentyseventeen_posted_on() {
// Get the author name; wrap it in a link.
$byline = sprintf(
_x( ‘by %s’, ‘post author’, ‘twentyseventeen’ ),
‘<span class=”author vcard”><a class=”url fn n” href=”‘ . esc_url( get_author_posts_url( get_the_author_meta( ‘ID’ ) ) ) . ‘”>’ . get_the_author() . ‘</a></span>’
);
// Finally, let’s write all of this to the page.
echo ‘<span class=”posted-on”>’ . twentyseventeen_time_link() . ‘</span><span class=”byline”> ‘ . $byline . ‘</span>’; // WPCS: XSS OK.
}

It is possible the code may be a bit different depending on what you have done with your website in the past. Simply go through the code and delete the parts that are about the author. If your code was identical to mine you would be left with the following:

function twentyseventeen_posted_on() {
// Finally, let’s write all of this to the page.
echo ‘<span class=”posted-on”>’ . twentyseventeen_time_link() . ‘</span><span class=”byline”> ‘ . $byline . ‘</span>’; // WPCS: XSS OK.
}

Congratulations, your website should now not display the author anywhere. As you can see the second method is a bit more involved and is different depending on the theme you use.

You Can Switch Back at Any Time

Deleting the author’s name in WordPress can be a big change and if you change your mind, it is quite easy to revert back. If you chose the plugin method, simply deactivate and delete the plugin.

For those of you that chose to use the coding method, you have two options to revert. You can either use a backup to restore your website or manually revert the code changes.

As long as you are happy with deleting the author’s name in WordPress and it is helping the image of your website, you may not need to switch back.

Why have you chosen to delete the author’s name in WordPress? Do you think it is better to have an author or not to have one?

Author: Ron Helms

I currently work for GreenGeeks as a Support Technician. My primary roles are supporting our VPS and Dedicated server clients, as well as performing site migrations. With experience in the web hosting industry since 2009, there is rarely a question I can’t help answer. In my spare time, I enjoy gaming and working on cars as an automotive enthusiast.

Was this article helpful?

Related Articles

Comments

  1. Hey, very informative but I have come across several issues while trying to do so.
    Firstly, the Show Hide author plugin no longer exists so that’s a major problem. Also, previously there was a code that was typed into the name box of the author which allowed the name to be hidden.
    Please let me know if these issues can be resolved.
    TIA

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.