Before connecting, make sure that the IP from which you will connect is added to the list of allowed in security settings MySQL.
To connect to a database using HeidiSQL, do the following:
3306