GoDaddy Help

Change my WordPress theme in the database

You can change your WordPress theme from within the database. This is an advanced method, but it can be helpful if you can't access WordPress dashboard due to an issue with your active theme.

Warning: Always make a backup of your site before making any changes to the database.

Note: You can only activate themes which are installed on your site.

  1. Sign in to phpMyAdmin.
  2. In phpMyAdmin, in the left menu, select the name of the database your site uses.
  3. Select the wp_options table (select the text, not the checkbox).

    Note: wp_ is the default database table prefix. If your table prefix isn't wp_, focus on finding _options. There should only be one _options table.

  4. Under the option_name column, find the template entry. You may need to navigate beyond the first page of entries.
  5. Select Edit next to the template entry.
  6. In the option_value column, change the value to the name of your theme. The new value must be the same as your theme's folder name. For example, to activate the Twenty Twenty-One theme, change the value to twentytwentyone.
  7. To save, scroll down to the bottom of the page, make sure that Save and then Go back to the previous page is selected and then select Go.
    Changing a WordPress theme in the database
  8. Select Edit next to the stylesheet entry.
  9. Repeat steps 6 and 7 to change the stylesheet information.

More info