How do I connect to a MySQL database remotely? Print

  • 37

You can connect to your MySQL database from a device other than our servers, but to do so you must first authorize the IP address of the device that wishes to connect to it:

  1. Log in to your control panel;
  2. In the"DATABASES" tab, select the"MySQL remote®" icon;
  3. In the"Add Access Host" field, enter either the IP address of the device to be authorized or the name of a domain to be authorized;
  4. Click on the"Add Host" button and you will see your new authorization in the"Access Hosts" list;
  5. You will then be able to connect to your MySQL database from this host, using your main domain name as the MySQL server name, for example:

Warning: Avoid deleting the IP address that you find in the default list of permissions: it is the one of the shared server itself. If you delete this authorization you will not be able to connect to your database from your hosted sites.

Tip: If, for example, to develop or test your database, you want to connect from your personal computer which unfortunately has a dynamic IP address (usually obtained via DHCP), you have two possibilities:

  1. Modify as indicated above your IP address each time you want to connect to your database. To find out your IP address, you can use our My IP address interface ;
  2. or use dynamic domain name services (DDNS - Dynamic Domain Name Server) such as No-IP, in which case you will only have to enter your dynamic domain name.

Was this answer helpful?