Connect remotely to MySQL database

Remote MySQL connection is disabled on our shared servers due to security reasons, but you can easily setup SSH tunnel between your PC and our server using SSH-client (for example, Putty) with the MySQL port (3306) forwarding. After completing it you will have port 3306 on your local machine listening and forwarding to your remote server's localhost on port 3306. Thus you can connect to the remote server's MySQL database effectively as though it were running on your local box. 

Follow these steps:

  • Run Putty
  • Create a session in PuTTY using your server IP-address as hostname and port 21098
  • Select the Tunnels tab in the SSH section
  • Put 3306 as source port and 127.0.0.1:3306 as destination

Remote access Putty

Click on "Add" button

Remote access Putty

Return to the Session tab and click Save
Run your session by clicking on "Open" button

Remote access Putty

Run your MySQL software on local machine and use 127.0.0.1 as server host, port 3306 and your database user login details.

Was this answer helpful?

Related Articles

Ruby on Rails

Ruby on Rails is a free web application framework for the Ruby programming language. It is often...

Check the number of inodes in cPanel

An inode is the abbreviation for index node. In Unix-based file systems, an inode is considered a...

how many CPU resources I'm using?

All of our shared hosting servers are equipped with the Cloudlinux operating system at this time,...

How to upload the content for addon domain

You have to upload the files for an addon domain to its directory. When you create a new addon...

Do you have any server resource restrictions?

Yes, we do.  Your account should NOT use more than 10% of the shared server CPU for a period...