Your MySQL server is probably not configured to accept requests from the host you're trying to access it from



Error Message

mysqli::__construct(): (HY000/2002): Connection timed out in

Other Information


Databases only accept connections from your website, not any others.


first i uploaded all the file and then i created database for my website, i edit my config.php using epizy filemanager only and i got this error but my php project is running properly on localhost???

What details did you use to connect to the database? (Don’t show your password)

$servername = "";
$username = "epiz_26351628";
$password = "***************";
$database = "epiz_26351628_********";

$conn = new mysqli($servername, $username, $password, $database);

Are you accessing your database from the same website in which it was created for?

yes I am using it on sub domain but I also tested in main domain

Try changing it from EPIZ.COM to EPIZY.COM


i got this error fixed i am using servername = “" in my php website but when i checked my wordpress’s config.php file so the servername = "” so i used “” instead of “
and my error resolved is not supposed to be used… it’s supposed to be

Both are same.


This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.