Do Deleted Wordpress Categories Create 404 Errors on Their Old URLs?

Sutra

Investor and Business Mentor
BuSo Pro
Joined
Oct 28, 2015
Messages
832
Likes
904
Degree
3
I feel like a dork for asking this, haha.

I deleted 10 Categories in Wordpress and expected they would create 404 errors, thus I would need to create 301's to redirect them. However, before creating the 301's, I ran Screaming Frog on my site (use the paid version so not running into any url limits) and none of the deleted categories showed up as a 404. In fact, the deleted category urls don't show up at all (I did a search within Screaming Frog to verify).

I don't have the Wordpress option set to have categories in urls. My urls look like: cars.com/how-to-choose-a-new-car/

But of course categories have their own slug so if the category is "New Cars" the category url looks like cars.com/new-cars/

And if you have nested categories, such as New Cars > Hondas then the category url will look like cars.com/new-cars/hondas

So two questions:
  1. If you delete a Category in Wordpress, does it create a 404 error?
  2. After you delete a Category, do you need to redirect (301) the Category url?
 
Last edited:
@Sutra, visit them manually and see what you get. You deleted the categories, which means your posts aren't in those categories, which means there's no links to those categories. So something like Screaming Frog, which crawls and only see's pages with links to them, wouldn't see these pages.

They should be 404 though. If you visit the old URL, it should toss up a 404 error and 404 page.
 
@Future State Thank you. Have a followup question about redirects. Couple years ago I used pagination. Eventually stopped and made everything 1 page. So I entered redirects for the paginated pages, i.e. cars.com/buy-new-car/2, cars.com/buy-new-car/3, cars.com/buy-new-car/4 were all 301'd to cars.com/buy-new-car/

Going through everything I just noticed that I have redirects entered for urls like: cars.com/buy-new-car/1/
However, after removing the redirect, if I enter cars.com/buy-new-car/1/ into the browser and go, it automatically goes to cars.com/buy-new-car/ (which is the correct page).

Does that mean that the url cars.com/buy-new-car/1/ is essentially the same as cars.com/buy-new-car/ ? Thus, I can remove those type of redirects? I have something like 100 of those redirects, hah.
 
Does that mean that the url cars.com/buy-new-car/1/ is essentially the same as cars.com/buy-new-car/ ? Thus, I can remove those type of redirects? I have something like 100 of those redirects, hah.

It sounds like you still have a plugin or something in your .htaccess that is causing the redirects. That's not native Wordpress functionality. Your cars.com/buy-new-car/page/2/ should return a 404 error if it doesn't exist. It shouldn't redirect to cars.com/buy-new-car/ without your intervention.

Actually, Wordpress might do this automatically. If you change the slug of a URL, it will automatically set up a 301 in the database for you. It might be the same for these paginated articles. I'm not sure as I don't use those. Should be an easy test to check.
 
Back