June 2, 2011

Remove /category/ from your WordPress url

If you wanted to be able to finally remove the useless /category/ from your WordPress categories permalinks? If yes, read on and get ready to hack your .htaccess file!

WordPress category permalinks are displayed that way:

  • http://www.domain.com/blog/category/wordpress

As you can see, the category in the url is pretty useless. Here’s how to remove it:

First backup your .htaccess file. Then, open it and append the following line:

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

Once saved, your categories pages will be displayed like this:

  • http://www.domain.com/blog/wordpress

Like it?

Wordpress # ,
Share: / / /

You might also like

Leave a Reply

Your email address will not be published. Required fields are marked *

Pin It on Pinterest

Share This