As part of my website redesign I needed to change around my categories. With over 600 posts this could be quit daunting, although I was keeping the categories with a lot of the posts. I did a quick Google search for WordPress bulk move category to look for tips and all I found in the top results were references to plugins. Nothing against plugins (I use many) but this isn’t something I wanted to test enough to trust on this site. I’d hate to miss a bug that corrupts my site.
Then I did what I should have done first. I listed the posts in a category and looked at the bulk edit options. And my solution was there. I had three things going for me:
- I’ve been excluding category pages from search engine indexes for a very long time. No need to worry about someone clicking a search result to find a “page not found” error.
- I was completely eliminating the categories.
- With only a very few exceptions, I was moving every post into an old category into an existing category then I was adding a tag with the old category name.
The process was simple (for the record I’m on WordPress 2.9.x).
- Go to categories in the WordPress administration panel and click on the number next to the category to list all the posts in the category.
- Select all the categories listed then select “Edit” under bulk options and click “Apply”. This will open a bulk edit box at the top of the screen.
- I selected the category I wanted everything in and I typed in the new tag (to match to old category name)
- I clicked “Update Posts”. This added the category to the existing selection(s) and added the tag to the existing tags. Nothing was removed.
- If there were a lot of posts I completed steps 1 through 4 multiple times to get through them all, one page of 25 at a time.
- I went back to categories and deleted the old category (Ok, first I listed the posts again and made sure everything was right.) Since the posts were already in another category the old category was simply removed.