One of the news sites I run covers finance, and by this summer it had 14 years of posts on it, a lot of which had nothing to do with money. I wanted them gone, and I wanted to know afterwards that every one I'd removed was returning the right status and that nothing I'd kept had been damaged along the way.
In September I removed 2,451 posts and 2,969 images from it. This is how the posts were chosen, the order things were deleted in, and what a crawl found a week later that my own checks had missed.
How the posts were chosen
I set the scope first, which was every post dated December 2025 or earlier, so anything from this year was left alone. That came to 6,076 posts, and each one was marked as on-topic or off-topic from its headline and its category. 3,625 were kept and 2,451 were marked for deletion.
Judging from the headline and category is quick, but it's the weak point of the method, because nobody read the body of each post. On another site where I ran the same audit, the least consistent calls were stories about contract wins and defence procurement, which can be business news or can be nothing of the sort depending on what the article says.
The cautious way to do a clean-up like this is to remove only the off-topic posts Google hasn't indexed, which is what I'd done on a different site earlier. I decided against it here, because an off-topic post is off-topic whether Google has indexed it or not. 718 of the 2,451 were indexed, and they went with the rest.
The order I deleted in
I worked a year at a time, oldest first, and inside each year the order was the 410 rule, then the images, then the posts. The rule goes in first so that there's no gap where a deleted address returns a 404.
The rules were the slow part to begin with. Adding them one call at a time through the redirect plugin was the biggest time sink of the whole job, and its import function turned out to take 500 rules in one go, which did 966 rules in about 20 seconds. The import has to be in the same shape as the plugin's own export file, though, and if it isn't, it reports that it created nothing and gives no error.
The images needed more care than I expected. WordPress lets one image be used by several posts, so if you delete every image attached to an off-topic post, you take the featured image off posts you're keeping. Before anything was deleted, I built a list of every image used by a kept post, which came to 3,919, and the delete step skipped anything on it. That list saved about 90 images.
What I checked afterwards
- A sample of 92 deleted addresses across the years, and all 92 returned 410.
- A sample of 65 kept posts, and all 65 returned 200.
- A sample of 40 protected images, and all 40 returned 200.
- The number deleted in each year against the number marked for that year, and they matched for all 14 years.
The check on the kept posts found something else, which was that hundreds of live posts on the site were already returning 410 because of an old list I didn't know about. I've written that up separately in an old 410 list was returning Gone for 624 live pages.
What my checks missed
A week later I ran a full crawl of the site, 20,232 addresses, and it found 69 that returned 404. My first check said none of them were from the clean-up, because I compared the 69 against my deletion list as text and nothing matched.
That was wrong, and six of them were mine. The site serves posts at two address patterns, one with the day in the date and one without, and I'd written the rule for only one of them. So, the lesson is to match a deletion list by the post's slug and never by the whole address. The same crawl did confirm the main job, because 1,304 removed posts in it returned 410.
The crawl also made me fetch the target of every redirect on the site, which I hadn't done, and 145 of the 359 older 301 redirects pointed at a page that was itself dead. I changed 144 of them to return 410 directly. A handful of addresses with unusual characters in them needed two rules each, one for the raw address and one for the encoded form, or they still returned 404.
Does it matter whether it's a 410 or a 404?
According to Google, less than people think. Its page on how HTTP status codes affect its crawlers says:
All 4xx errors, except 429, are treated the same: Google crawlers inform the next processing system that the content doesn't exist.
Google, HTTP status codes and Google's crawlers

I still use 410, because it makes my own checking simpler. On a site where I've just removed thousands of posts, a 410 is something I did on purpose and a 404 is something I need to look at, which is how those six missed rules showed up at all.

What it did for the site
I can't give you a clean traffic result. On 8 September, four days after the clean-up, I checked 20 recent posts in Search Console and only 2 were indexed, with the other 18 crawled and not indexed. On 11 October, 19 of 20 were indexed, and new posts were being indexed within about a day. I'd like to say the clean-up did that, but a Google spam update ran from 24 September into October, and I changed other things in the same weeks, so I can't separate them.
What I'd do
In this order, because each step protects you from a mistake in the next one:
- Set the scope in writing before you look at a single post. A date range and a definition of on-topic, so the decision doesn't drift as you go.
- Build the list of images used by posts you're keeping. It has to exist before anything is deleted, because a deleted image doesn't come back.
- Add the 410 rule, then delete the images, then the posts, one year at a time, so a problem shows up in a small batch.
- Check a sample of deleted and kept addresses after each year, by requesting the pages and reading the status, and count what was deleted against what was marked.
- Run a full crawl a week later and match its 404s to your list by slug. It'll find the address patterns you didn't know the site had.
- Fetch the target of every existing redirect. Mine had 145 pointing at dead pages, and no report had told me.
There's more on status codes, crawling and indexing on the technical SEO page.
This post sits under technical SEO in the knowledge base, which is where I set out what Google says on it and what the published studies found. The rest of what happened on my own sites is on the blog.