How to Delete all WordPress Meta Fields

If you have the need to delete all your meta fields from your WordPress site, then there are basically two ways you could go about it. You could manually delete your meta fields. You could use a plugin. Or you could go into your database and delete your meta fields from there.
We’ll go over each method below.
No matter which method you choose, of course you should first back up your database in case something goes wrong and you end up deleting things you don’t want to delete.

Delete with a Plugin

If you’d like to use a plugin to do this work, then the WP Bulk Delete Plugin should do the trick for you.

  • First go to your Post section in the Admin area of your backend.

The Bulk Delete plugin lets you choose to delete Meta Fields based on a number of different options. For example, you can delete Meta Fields based on …

  • Post Meta
  • User Meta
  • Comment Meta

Delete Post Meta

  1. Post type:-you can delete Post Meta by choosing post type post/page..
  2. Post:-you can select post whose post meta field you want to delete.
  3. Meta fields:-you can delete a post by only meta key.if you want to delete post meta key and its value so also you can do it easily using this plugin.
  4. Date interval:-you can also set a date interval for post whose meta fields you want to delete.if you leave these fields blank for delete all meta.

Delete User Meta

you can delete user meta by user roles.

  1. Meta fields:-you can delete a User Meta by only meta key.if you want to delete user meta key  and its value so also you can do it easily using this plugin.
  2. Date interval:-you can also set a date interval for users whose meta fields you want to delete.if you leave these fields blank for delete all meta of users.

Comment Meta

You can delete comment by meta key or meta value.
Date interval:-you can set date interval for delete comment meta field.

Delete All WordPress Meta Fields Using phpMyAdmin

You can also quickly delete all WordPress Meta Fields  using MySQL or phpMyAdmin. This method is only recommended for more advanced users.
Login to cPanel dashboard of your WordPress hosting account. Under the database section, click on phpMyAdmin.

Inside phpMyAdmin, you will need to locate your WordPress database. You will see a page like this showing all your WordPress database tables.

  • Post Meta

Check the box next to  wpprefix_postmeta table. The name of your posts tables may differ depending on the table prefix you choose during your WordPress installation.

you can delete postmeta using meta_key and meta_value .
After selecting checkbox of postmeta fields click on delete button.
PhpMyAdmin will now show you a warning asking if you really want to delete those fields.

That’s all,this post helped you learn how to easily delete post meta fields in WordPress

  • User Meta

Check the box next to  wpprefix_usermeta table. The name of your posts tables may differ depending on the table prefix you choose during your WordPress installation.

you can delete usermeta using meta_key and meta_value .
After selecting checkbox of usermeta fields click on delete button.
PhpMyAdmin will now show you a warning asking if you really want to delete those fields.

That’s all,this post helped you learn how to easily delete user meta fields in WordPress

  • Comment Meta

Check the box next to  wpprefix_commentmeta table. The name of your posts tables may differ depending on the table prefix you choose during your WordPress installation.

you can delete comment meta using meta_key and meta_value .
After selecting checkbox of comment meta fields click on delete button.
PhpMyAdmin will now show you a warning asking if you really want to delete those fields.

That’s all, this post helped you learn how to easily delete post meta fields in WordPress

That’s all, we hope this article helped you learn how to easily delete all meta fields in WordPress.

 

Published by Karan Gadhavi

Karan Gadhavi is WordPress Developer and Passionate Blogger ( mostly blog about WordPress ). Enjoying life at Ahmedabad, India

    Leave a Reply

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

    We strive to be the best and make awesome work

    Get a quote for your next project.