It’s possible that you don’t always want the category to display in the URL of your post. For example, your blog is based on multiple niches, and there are many categories. When someone visits your blog’s category, However, the URL will appear as www.yourdomain.com/category/your-category-name

But you do not want the category to be visible in your URL. In this article, we’ll take a look at how you can remove the category from WordPress URLs without affecting any functionality on your site. 

The article provides you four methods to Remove category from WordPress URL. You can check or skip to the area you’re interested in.

Remove Category From your URL in WordPress

Although WordPress comes with the defaults option for showing the URL of your category page, like this www.yourdomain.com/category/your-category-name, But you can also remove the category. This can be done from the WordPress dashboard. If you only need to delete a category from your URL, it’ll only take a few minutes.

lagreca busted open BoomDevs

Method 1: Remove categories from through WordPress settings 

Follow my instructions to remove the category from your URL.

  • Log in to your WordPress dashboard
  • Go to Setting >> Permalink 
  • Select Custom Structure and paste /%category%/%postname%/
  • Make a change to the Category base, put a dot(.) there.
  • Save the changes.
Remove category from WordPress URL from setting BoomDevs

You must ensure two things: that /%category%/%postname%/  is entered on the custom structure, and a dot is placed on the Category base. 

It will not work until you put a dot(.) on the Category base. By navigating through your category pages after saving the procedure, you can observe the changes. You’ll see that your URL doesn’t have any category text.

Method 2: Remove category from WordPress URL with the help of a plugin.

You can also do this with the help of plugins. You’ll need to install the Remove Category URL plugins to do so.

Screenshot 3 3 BoomDevs

You can use this plugin to remove the category from your URL. It’s also a simple plugin; you don’t need to do anything to remove the category from your URL. This plugin will remove the category from your URL automatically. It’s also compatible with WPML. So if you’re using WPML, you won’t have to worry about it.

Method 3: Remove category from WordPress URL with the help of Yoast SEO plugin.

With millions of users worldwide, Yoast SEO is can be go-to solution for optimizing your WordPress website’s visibility and attracting organic traffic. This plugin equips you with essential tools to navigate the complexities of search engine optimization. From streamlined setup to advanced technical optimizations and content analysis, Yoast SEO can empowers you to take control of your website’s SEO effortlessly. Now lets see a step-by-step guide for removing categories from URLs using the Yoast plugin.

Step 1: Access Yoast SEO Plugin
First, make sure you have the Yoast SEO plugin installed and activated on your WordPress website. If you don’t have it installed, you can easily find and install it from the WordPress Plugin Repository.
Once you have the plugin installed and activated, follow these steps:

Step 2: Navigate to the Settings
In the left-hand menu, find and click on “Yoast SEO.” This will expand a submenu.
Click on “Settings” to access the Yoast SEO settings.

Step 3: Access the Categories Settings
Select a category and scroll down to the bottom of the list. 

Step 4: Disable Category Prefix
You will see an option labeled “Show the categories prefix in the URL.” By default, this option is enabled, causing category prefixes to be included in your post URLs.
To disable the category prefix, simply click on the toggle switch next to this option. It should change from “On” to “Off.”

Step 5: Save Your Changes
After turning off the category prefix, scroll down to the bottom of the page. Click the “Save Changes” button to save your settings.

Rank Math 2 BoomDevs

You’ve completed all of your work with the Yoast SEO plugin. After you complete this step, your category text will be removed from the URL. There’s nothing else you need to do.

Method 4: Removing Category From Your URLs With Rank Math Plugin

Rank Math” is another game-changing SEO plugin that empowers your digital presence. With a host of intelligent features and cutting-edge capabilities. You can easily enhance your website’s visibility, rankings, and overall performance with Rank Math’s intelligent features, automation capabilities, and user-friendly design. Let’s look at how you can remove category slag from the URL if you are a Rank Math user.

Step 1: Go to Rank Math
Go to the Rank Math plugin in your WordPress dashboard to begin. Go to the “Plugins” section and search for “Rank Math SEO.” Install and activate the plugin if you haven’t already.

Step 2: Navigate to General Settings
Once Rank Math is installed and activated, you’ll find it in your WordPress admin menu. Hover your mouse over the “Rank Math” option, and you’ll see a submenu. Click on “General Settings” to access the plugin’s general configuration.

Step 3: Click on Links
In the Rank Math General Settings, you will find several tabs on the left sidebar. Click on the “Links” tab. This tab allows you to configure various settings related to your website’s permalinks and URL structure.

Step 4: Turn on “Strip Category Base”
At the first of the page you will find “Strip Category Base”. This option allows you to remove the category base from your category URLs. By default, it is usually set to “Off.” Toggle the switch to “On” to enable the “Strip Category Base” feature.

Step 5: Save Your Changes
After turning on the “Strip Category Base” option, make sure to save your changes. Locate the “Save Changes” button at the bottom of the page and click on it. This will update your Rank Math settings and apply the change.

Yoast SEO 1 2 BoomDevs

Method 5: Removing Category From Your URLs With .htaccess

Using .htaccess, you can remove categories from your URLs. It’s a manual process that can be completed manually. However, if you make a mistake, it may harm your website.

RewriteRule ^category/(.+)$ http://www.yourdomain.com/$1 [R=301,L]

All you have to do now is copy and paste the code into your .htaccess file. Replace yourdomain with your website domain. The category will no longer appear in your URL after that.

Wrapping Up

How to remove category from WordPress URL has already been discussed. We provide four methods. You are free to use any of it. However, if you’re using the plugin (method 2) to remove the category from the URL, we don’t recommend using it. I’m telling you this because the more plugins you use, the longer it will load. You can do this from the Yoast SEO plugin if you’re a Yoast SEO user. If you don’t want to use Yoast SEO, you can use the first method.

 You can read the following articles also :

Quickly Embed Spotify Playlist in WordPress (2021)

How to Make WordPress Site Private in 2021

Like this article? Spread the word