How to Rename a MySQL Database
cPanel includes a database rename tool. Remember that renaming changes what your application must connect to, so update its config afterwards.
Step-by-step
- Back up the database first via export.
- Open Databases → MySQL Databases in cPanel.
- Find the database under "Current Databases" and click the Rename action next to it.
- Enter the new name (your account prefix is kept) and confirm.
- Update your application config with the new database name — for WordPress, edit DB_NAME in wp-config.php.
- Reload the site and confirm it connects; if not, re-check the config name and the user's access (see connection errors).
💡 Good to know
- The connected user keeps its access through a rename, but the app config must still be updated.
- Renaming on a live site causes brief downtime until the config is updated — do it during quiet hours.
- Always note the exact new name including the youruser_ prefix.