Resolve Error : Eclipse SSH key is not matching the SSH key(s) that is associated with your Heroku account

We have seen that how to create First Heroku application using Eclipse. However it is possible that after following all steps properly in above article you may receive error saying

the Eclipse SSH key is not matching the SSH key(s) that is associated with your Heroku account. To fix this error, you can: – Associate your SSH key to your Heroku account by going to “Preferences” OR – If the SSH Key is correct, restart Eclipse

Eclipse and Heroku SSH key is not matching
Eclipse and Heroku SSH key is not matching

However, if you will login to heroku, you will find that application is already created. Error is only at Eclipse end.

To resolve this error, we need to switch from current View to Git View.

Copy Git URL from Heroku application by navigating to “Your Application | Settings | Info | Git Url” in Heroku.

Now in Eclipse Git View, Clone above Heroku application.

Clone Git from Heroku
Clone Git from Heroku

While providing Git URL, do not provide username and password, as RSA key is already in Heroku and on your local System.

It will prompt that “Do you want to add Heroku in known Host ?”, click yes. Because of this only we were getting an error.

Now try to create application in Heroku as per this article and you should be able to create without any error.



  1. Hi,

    I tried with the above. I am getting the error as shown in the screen shot below. Can you please tell me why I am getting this error.

  2. I ran into this issue for the first time today after my machine was re-imaged. After hours or trying to get local SSH keys to sync with my Heroku account I found this article and tried the proposed solution – just do a git clone from the Heroku Git URI and it worked. I was never asked to add to my known hosts file because it was already there… BUT when I tried to then import my existing Heroku app into Eclipse it worked. I do now have 2 git clones of the Heroku app but I can just delete the first one and hopefully now have my Herkou app in Eclipse for further development and deployment back to Heroku.

    Many thanks !!

Leave a comment

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.