Support » Installing WordPress » Can´t install wordpress: Error establishing a database connection

  • Resolved tuviejaenbolas


    Hi, so we have and we want to install wordpress on and we can´t we keep getting “Error establishing a database connection”, there are no credentials, so it is not a credentials problem. there is not wp-config.php, there is the example, because as I extract the files I can´t access the installator,I keep getting the error.

    We tried creating a DB manually for the same webspace and renaming the wp-config example to wp-config.php, editing with the same info of the DB we create manually without success.Always same errror, we tried copying a DB and wp-config from a different wordpress without success too. We made our own script and connected to the DB, so credentials were good.

    But in the real scenario,it happens immediately, before the db is created.

    This is a Plesk on debian, hosted on AWS.

    Thank you.

Viewing 4 replies - 1 through 4 (of 4 total)
  • You will need to create the DB, DB User and DB password before installation.
    Also give the DB User all permissions.

    Then run the install by going to
    or if necessary

    It will ask you for the DB Name, Username and PW.

    Just decompress the zip and run the install.

    You can not use another website’s database or config.

    Make sure you are running PHP 7 on your server



    HudsonValleyWebDesign thank you for your answer.
    I found the problem and it was when creating the DB I left remote connection instead of local connection. Now works.

    Thank you very much.

    Hi tuviejaenbolas,

    I have same error. Could you please be more specific how did you solve it?

    Thanks in advance,



    Hi Birdy, I guess it will help you only if you are using Plesk.
    The problem was when creating the DB it was automatically defined with “remote access”, when I paid attention I created the DB specifying local connection and worked.
    Please update me if it was your same problem.

    Thank you.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Can´t install wordpress: Error establishing a database connection’ is closed to new replies.