I’ve talked before about how important it is to reduce the size of the WordPress database to make it more efficient, and showed two plug-ins recently to reduce the number of revisions stored for each post in the database.
But there is another area that can grow in the database if you’re not careful, and that’s the spam comments.
Whichever system you use to block spam comments (e.g. Akismet), they still stay in the database in case they were a false positive and you want to recover them, at least for a while.
Luckily there’s a simple button in WordPress to remove those comments, once you’re happy that they don’t need them.
Step 1: Go to the spam comments
If the number of spam comments is shown in the dashboard, click on it:
If you use Asikmet, then you’ll need to click on the spam queue link:
Step 2: Click on “Empty Spam”
Akismet appears to tidy up the comments after a while anyway, but at least one site that I’ve checked recently had never deleted the spam comments ever – there were 4 years worth in there!