Skip to content

How to remove a category prefix from WordPress URL?

When you have several categories in your WordPress site, the URL to the specific category will be like this make it looks more professional,  some blogger wants to remove the category prefix from the URL and make it like this  The new URL is shorter and more professional. 

In this article, we will introduce how to remove the category prefix from the WordPress URL. 

1. Remove it from the WordPress Permalink setting

  • Log in to your WordPress admin dashboard.
  • Navigate to “Settings” and click on “Permalinks” in the menu.
  • In the “Permalink Settings” page, you’ll see different options for URL structures. By default, WordPress includes the category base in the URL structure.
  • To remove the category prefix, select the “Custom Structure” option.
  • In the input field next to the “Custom Structure” option, enter the desired permalink structure for your URLs. You can use different tags to define the structure. For example, if you want to remove the category base completely, you can use /%category%/%postname%/. to replace /%postname%/
  • After entering the desired permalink structure,input a dot “.”in the category base, click the “Save Changes” button to save your settings.Remove category prefix from URL
Before removing the category prefix
category prefix
After removing the category prefix
without category prefix
The update will affect your current existing URLs which you share on social platforms.  Please remember to replace all the broken URLs after you remove the category prefix, otherwise, it may result in broken links or 404 errors on the page.

2. Use plugins to remove the category prefix in the URL. 

Using plugins to remove the category prefix in the URL is another alternative method. 

Use Yoast SEO Plugin

2. 1  Go to WordPress Dashboard -> Plugins -> Add New-> Search Yoastyoast seo
2.2 Install and activate Yoast SEO. Skip the setting if you don’t want to use other functionalities of Yoast. Go to Setting, scroll down and find Categories & tags.Yoast SEO setting
2.3 Select Categories, and scroll down to find 2 switches. Choose the one at the bottom and switch it off.
swtich off category prefix
 2.4. Switch off the “show the categories prefix in the slug”, after that save the change.  In this way, you have removed the category prefix in the WordPress URL change

 Wrapping up

There are several methods you can use to remove the category prefix in the WordPress URL. Some bloggers can remove it by editing the .htaccess file. However, it’s risky for beginners to do so.  Changing the setting of the WordPress permalink and using plugins are both easier to remove the category prefix in the URL.