How to connect to AWS ec2 instance using Putty & SSH

Learn the simple steps to connect any Amazon ec2 Instance via SSH and Putty client on Windows 11, 10, or 7 operation systems…

If you have just created a new Linux instance on Amazon cloud and want to access it remotely using Putty via SSH protocol then here are the steps to follow…

Connect Aws ec2 Linux or Windows instance via SSH using putty

When you create an ec2 Instance, it asks you to create and download a PEM key file on your system. So, I am assuming you already have the Private .pem key file of your instance and if not then see our article- Create Private Key for AWS Instances for SSH.

 

1: PuTTy Key Generator- Load an existing private-key file

Go to the Windows 10/11 start menu and search PuTTYGen. Once it appears, click on the Load button.

Load an exisitng Private key filwe

 

2: Open Pem Key

Click on the drop-down box and select “All Files“; after that navigate to the place where you have saved your downloaded “Ec2 instance.Pem” Private key and select it to open.

Save PPK key

 

3: Convert and Save PEM to PPK key

Now, click on the “Save Private Key” button and then click on the “Yes“. Give some name to your newly generated PPK key and save it on your system.

Convert .PEM key to .PPk private key

 

4. Configure Putty HostName

Under Session, go to the Host Name box and typeec2-user@publc-ipaddress. Replace public-ipaddress with the address of your ec2 instance that you want to connect over SSH.

After that click on the “Save” button.

Putty settings SSH for Ec2

 

5. SSH Authentication

Now, go to Auth from the Putty’s Category section, click on the Browse button to select the newly generated.PPK key that you saved in the 3rd step.

After that click on the “Open” button.

Add PPK to Putty for AWS Instance

 

6. Login

Finally, you will have a Security warning – with two options “Accept” and Connect Once“. For security, if you are using some PC that is not yours then select “Connect Once“. Whereas on your personal system where you don’t want to add key again and again in PuTTy, then simply select “Accept” to let the Putty store Server’s host key in the cache.

Putty Security Alert

Use putty command terminal to access ec2 AWS instance

 

Leave a Comment

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