Top

Daily Tip: How to Find the Hostname of Your Database Server When Installing WordPress

October 1, 2011

If you’re setting up a brand new installation of WordPress, you will need to know the value to put in your wp-config.php file for Database Host.

Be aware that this is not the same value for everyone who is installing WordPress. It’s unique to your hosting company.

Here’s an example of what we’re looking at:

define('DB_HOST', 'MyDatabaseHost'); // Example MySQL Database host

Most of the time the DB_HOST value is going to be localhost. However, it varies depending on your host. For example, DreamHost might have a value of mysql.example.com and 1and1 might have a value that looks something like this: db12345678. It depends on where your host stores the databases for your particular hosting account.

The WordPress codex has a list of possible values for a handful of hosting companies on the Editing wp-config.php page. If you’re not sure, just check your host’s documentation or contact tech support. They’ll be able to let you know the hostname for your database server.

Comments

Got something to say?

Bottom
Article Archive  |  This site is a historical archive of pressography.com, a WordPress plugin and theme blog that published between 2006 and 2012. It is preserved for reference and is not operated by, affiliated with, or endorsed by its original authors. Nothing here is for sale and no form on this site is active. If you are the original owner and would like this domain returned, please get in touch.