WordPress plugin
Better Search Replace Pro
Better Search Replace Pro searches and replaces values in a WordPress database, including during a move to a new domain or server. It uses WordPress's native database functions and supports serialized data across all tables.
Better Search Replace Pro searches and replaces values in a WordPress database, including during a move to a new domain or server. It uses WordPress's native database functions and supports serialized data across all tables.
Set the scope and preview
Select specific tables when an operation should not cover the whole database. A dry run shows how many fields would be updated before you apply the replacement.
After a completed search and replace, Pro lets you view exactly what changed. It also works with database backup and import while a search and replace is running. Check the search and replacement values carefully and make an appropriate backup before applying changes; an incorrect value can damage the database.
Save options for repeat work
Custom profiles shop search and replace settings that you can load for similar tasks later. Pro also includes priority email support from the developer, plus support and updates for one year.
Multisite access
Subsite administrators can search and replace within tables belonging to their own subsite. Network administrators and administrators of the primary site can work across all tables from the primary website's WordPress admin. Plugin access can be changed in code with the bsr_capability filter.
For a website URL change
When moving a site to a new server and changing its URL, follow these steps:
- Back up the database on the current site.
- Install the database on the new host.
- On the new host, define the new site URL in the
wp-config.phpfile. - Log in at the new admin URL and use Better Search Replace to replace the old site URL with the new one.
- Delete the site URL constant added to
wp-config.php.
You may also need to regenerate the .htaccess file by opening Settings > Permalinks and saving the settings.
Open the tool
Install and activate Better Search Replace Pro in WordPress, then go to Tools > Better Search Replace in the admin. Enter the search and replacement values, choose tables, execute a dry run, and review its field count. Back up the database and apply the operation after checking the values.