Rename Custom Field in WordPress Database

You can use the following snippet to rename a custom field directly in the WordPress database:

UPDATE `wp_postmeta` SET `meta_key` = 'NEW_CUSTOM_FIELD_NAME' WHERE `meta_key` = 'OLD_CUSTOM_FIELD_NAME'

Caution: Always create a database backup before manipulating the database!

Leave a Comment

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

Scroll to Top