WordPress Powered

Mass Delete WordPress Comments

Every once in a while you may find yourself needing to mass delete WordPress comments in bulk for either SPAM comments, pending comments, approved comments or already trashed comments.

With access to your database and the ability to run a SQL command you can do any of the above with the proper line of SQL. I keep the below in a quick reference sheet but figure that other’s may find these useful, please use as needed but with caution. The below will remove comments from the default database prefix wp_.

*Always have a backup of your database before making large edits.

Mass Delete WordPress SPAM Comments

DELETE from wp_comments WHERE comment_approved = 'spam'

Mass Delete WordPress Pending Comments

DELETE from wp_comments WHERE comment_approved = '0'

Mass Delete WordPress Approved Comments

DELETE from wp_comments WHERE comment_approved = '1'

Mass Delete WordPress Trashed Comments

DELETE from wp_comments WHERE comment_approved = 'trash'


share this:

like this:

Leave a Reply

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