Skip to main content
Keep Your Business Open During COVID-19Learn More
Call us
Phone numbers and hours
Help Center

Explore our online help resources

Help

GoDaddy Help

Remove all WordPress comments before a specific date

You can remove all WordPress comments submitted by your users before a specified date.

  1. Log into phpMyAdmin (cPanel / Plesk / Web Hosting / Managed WordPress).
  2. Select the database for your WordPress site in the left-hand column.
  3. Click the SQL tab.
  4. Enter the following command into the "Run SQL query..." box:
    DELETE from wp_comments WHERE comment_date <= 'YYYY-MM-DD HH:mm:ss'

    Update the command for your situation as follows:

    • YYYY is year
    • MM is month number
    • DD is the day
    • HH is the hour
    • mm is the minute
    • ss is the seconds

      If you do not want to specify the time you can enter 00:00:00 for that part of the command.

    Warning: If your WordPress database uses custom table prefixes, then you must replace wp_ in each command with the prefix listed in your wp-config.php file.
  5. Click Go.

More info

Community Related

Clare-Hawaii's Avatar
Removing date & Adding Facebook comments

3 Replies

Last posted almost 3 years ago.

PaloAltoBruce's Avatar
Turn off Recent Posts, Recent Comments, and Archive

5 Replies

Last posted about 1 year ago.

hithereperson's Avatar
Remove comments in Ascension (Primer)

3 Replies

Last posted almost 3 years ago.

Atancc's Avatar
Hosting membership

1 Replies

Last posted over 4 years ago.

dil123's Avatar
Domain Transfer before expiration date

2 Replies

Last posted over 4 years ago.

Don't see what you are looking for? Search the Community