How to Set Up a Free VPN Server in AWS Cloud

How to Set Up a Free VPN Server in AWS Cloud

Learn how to set up a secure, personal VPN server in the AWS cloud using OpenVPN—completely free under the AWS Free Tier.

Required Tools:

– A Computer.
– SSH-capable terminal (Linux/macOS) or PowerShell/Command Prompt (Windows)

Things Needed?

– AWS Free Tier account

Steps to configure the How-to Schema:

Step 1

Create or log into your AWS Free Tier account at aws.amazon.com.

Step 2

In the AWS Console, go to “Services” > “EC2” under the “Compute” section.

Step 3

Click “Launch Instance” and then choose “AWS Marketplace” on the left sidebar.

Step 4

Search for “OpenVPN” and select the free-tier eligible OpenVPN Access Server (not the one limited to 10 devices).

Step 5

Choose the instance type t2.micro (free-tier eligible), and proceed with launch.

Step 6

Create a new key pair, download it, and keep it secure (you’ll need it for SSH access).

Step 7

After the instance launches, copy the example SSH connection command from AWS and adjust it to point to your key file (e.g., Downloads/vpnserver.pem).

Step 8

Open your terminal (Linux/macOS) or PowerShell/Command Prompt (Windows) and connect using the SSH command.

Step 9

Accept the license agreements by typing yes and pressing Enter through the prompts.

Step 10

Reconnect as the openvpn user instead of root by changing the SSH username.

Step 11

Run the command sudo passwd openvpn to set your admin/client password.

Step 12

Return to the EC2 dashboard and copy your instance’s IPv4 Public IP.

Step 13

In your browser, go to https://[Your.IP.Address]:943/admin and log in with username openvpn and the password you just set.

Step 14

In the admin portal, go to “VPN Settings” > “Routing” and select “Yes, all client traffic should be routed through the VPN.” Save settings and click “Update Running Server.”

Step 15

To connect as a user, go to https://[Your.IP.Address]:943/ (remove “admin” from the URL).

Step 16

Log in with the same openvpn credentials, select your device type, and download the VPN client.

Step 17

Install the VPN client, launch it, and log in with the same credentials.

Step 18

Confirm the VPN is working by going to Google and typing “What’s my IP?”—it should match your VPN server IP.

Step 19

For mobile devices, use the links in the user portal to download the OpenVPN app and follow the instructions.


Discover more from Michael Allen

Subscribe to get the latest posts sent to your email.

Leave a Reply