Title: Moving WordPress
Last modified: August 24, 2016

---

# Moving WordPress

 *  [JoePhilpott](https://wordpress.org/support/users/joephilpott/)
 * (@joephilpott)
 * [11 years ago](https://wordpress.org/support/topic/moving-wordpress-41/)
 * Hi,
 * I’m in the process of moving a website by following the advice of [https://codex.wordpress.org/Moving_WordPress](https://codex.wordpress.org/Moving_WordPress).
 * However, I get the following error message:
 * ———————————————————————————————
    Warning: mysql_connect() [function.mysql-connect]:
   Access denied for user ‘‘joelightfm’’@’localhost’ (using password: YES) in /var/
   www/vhosts/newboldnsa.co.uk/test.newboldnsa.co.uk/wp-includes/wp-db.php on line
   1416 Error establishing a database connection This either means that the username
   and password information in your wp-config.php file is incorrect or we can’t 
   contact the database server at 127.0.0.1. This could mean your host’s database
   server is down.
 * Are you sure you have the correct username and password?
    Are you sure that you
   have typed the correct hostname? Are you sure that the database server is running?———————————————————————————————
 * I’ve checked, double checked and tripple checked and the db name, username and
   password are all correct.
 * I’ve tried changing ‘localhost’ to ‘localhost:3306’ and even 127.0.0.1 but none
   of this has helped.
 * Can someone please help?
 * Thanks!!

Viewing 1 replies (of 1 total)

 *  Moderator [t-p](https://wordpress.org/support/users/t-p/)
 * (@t-p)
 * [11 years ago](https://wordpress.org/support/topic/moving-wordpress-41/#post-6036879)
 * > I’ve tried changing ‘localhost’ to ‘localhost:3306’ and even 127.0.0.1
 * – Have you asked your hosting provider as what it should be?
    – Then make sure
   wp-config.php is in right location. – if all that information is correct your
   database probably has a problem with it. Contact your hosting provider if the
   database server is offline (if the problem suddenly happened), or if they have
   any other problem at their end, or they made any changes to your account, or 
   if there are any limitations/restrictions, or if the hosting package is set to
   Windows and not Linux, etc. – In case the error is intermittent then it’s your
   server. What’s happening is that the web server and/or the database server are
   gettign overloaded and the connection is droping out or is refused for a short
   time. That gives you the database error as the website can’t connect to the database.
   To fix this, you’ll need to talk to your hosting company as they are the only
   ones that can do anything about hardware issues like this. – There are also many
   threads on this topic on these forums: [http://wordpress.org/search/Error+establishing+a+database+connection?forums=1](http://wordpress.org/search/Error+establishing+a+database+connection?forums=1)

Viewing 1 replies (of 1 total)

The topic ‘Moving WordPress’ is closed to new replies.

## Tags

 * [moving-wordpress](https://wordpress.org/support/topic-tag/moving-wordpress/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 1 reply
 * 2 participants
 * Last reply from: [t-p](https://wordpress.org/support/users/t-p/)
 * Last activity: [11 years ago](https://wordpress.org/support/topic/moving-wordpress-41/#post-6036879)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
