Find the home, siteurl, and theme for a WordPress installation:

You may find the “home” and “siteurl” in the database using an SQL query in phpMyAdmin while in the database:

SELECT * FROM `wp_options` WHERE option_name=’home’ OR option_name=’siteurl’ OR option_name=’theme’;

You may find the “home” and “siteurl” in the database using an SQL query in shell (SSH):

mysql -p -u DBUSER DBNAME -e “SELECT * FROM `wp_options` WHERE option_name=’home’ OR option_name=’siteurl’ OR option_name=’theme’;”

You should also check the “wp-config.php” file for an override such as:

define(‘WP_HOME’, ‘http://example.com’);
define(‘WP_SITEURL’, ‘http://example.com’);

* The override above is a good way to temporarily use a different URL for WordPress.  You may also modify the values in the database:

In phpMyAdmin:

UPDATE `wp_options` SET =’http://somehost.local’ WHERE option_name=’home’ OR option_name=’siteurl’;

In shell (SSH):

mysql -p -u DBUSER DBNAME -e “UPDATE `wp_options` SET =’http://somehost.local’ WHERE option_name=’home’ OR option_name=’siteurl’;”

If you need to access the database and need the credentials, you can look into the “wp-config.php” files.