Connect to RDP using WARP
Cloudflare WARP to Tunnel allows users to connect to RDP servers using their preferred RDP client. Cloudflare Tunnel creates a secure, outbound-only connection from your RDP server to Cloudflare's global network; this requires running the cloudflared
daemon on the server (or any other host machine within the private network). Users install the Cloudflare WARP client on their device and enroll in your Zero Trust organization. Remote devices will be able to connect as if they were on your private network. By default, all devices enrolled in your organization can connect to the RDP server unless you build policies to allow or block specific users.
This example walks through how to set up an RDP server on a Google Cloud Platform (GCP) virtual machine (VM), but you can use any machine that supports RDP connections.
- In your Google Cloud Console ↗, create a new project ↗.
- Go to Compute Engine > VM instances.
- Select Create instance.
- Name your VM instance, for example
windows-rdp-server
. - Configure your VM instance:
- Scroll down to Boot Disk and select Change.
- For Operating system, select Windows Server.
- Choose a Version with Desktop Experience, for example Windows Server 2016 Datacenter.
- Once your VM is running, open the dropdown next to RDP and select View gcloud command to reset password.
- Select Run in Cloud Shell.
- Run the command in the Cloud Shell terminal. You will be asked to confirm the password reset.
- Copy the auto-generated password and username to a safe place.
You can use any RDP client to access and configure the RDP server.
To access the server through Microsoft Remote Desktop:
- Download and install Microsoft Remote Desktop ↗.
- Once downloaded, open Microsoft Remote Desktop and select Add a PC.
- For PC name, enter the public IP address of your RDP server. In GCP, this is the External IP of the VM instance.
- For User account, select Add User Account and enter your auto-generated password and username.
- Select Add. The PC will display in Microsoft Remote Desktop.
- To test basic connectivity, double-click the newly added PC.
- When asked if you want to continue, select Continue.
You can now remotely access the RDP server using its public IP. The next steps will configure access to the server using its private IP.
- Create a Cloudflare Tunnel for your server by following our dashboard setup guide. You can skip the connect an application step and go straight to connecting a network.
-
In the Private Networks tab for the tunnel, enter the private IP or CIDR address of your server. In GCP, the server IP is the Internal IP of the VM instance.
-
(Optional) Set up Zero Trust policies to fine-tune access to your server.
To connect your devices to Cloudflare:
- Deploy the WARP client on your devices in Gateway with WARP mode or generate a proxy endpoint and deploy a PAC file.
- Create device enrollment rules to determine which devices can enroll to your Zero Trust organization.
By default, WARP excludes traffic bound for RFC 1918 space ↗, which are IP addresses typically used in private networks and not reachable from the Internet. In order for WARP to send traffic to your private network, you must configure Split Tunnels so that the IP/CIDR of your private network routes through WARP.
-
First, check whether your Split Tunnels mode is set to Exclude or Include mode.
-
If you are using Include mode, add your private network's IP/CIDR range to the list. Your list should also include the domains necessary for Cloudflare Zero Trust functionality.
-
If you are using Exclude mode:
a. Delete your private network's IP/CIDR range from the list. For example, if your network uses the default AWS range of
172.31.0.0/16
, delete172.16.0.0/12
.b. Re-add IP/CIDR ranges that are not explicitly used by your private network. For the AWS example above, you would add new entries for
172.16.0.0/13
,172.24.0.0/14
,172.28.0.0/15
, and172.30.0.0/16
. This ensures that only traffic to172.31.0.0/16
routes through WARP.You can use the following calculator to determine which IP addresses to re-add:
Results:172.16.0.0/13
,172.24.0.0/14
,172.30.0.0/16
In Base CIDR, enter the RFC 1918 range that you deleted from Split Tunnels. In Excluded CIDRs, enter the IP/CIDR range used by your private network. Re-add the calculator results to your Split Tunnel Exclude mode list.
By tightening the private IP range included in WARP, you reduce the risk of breaking a user's access to local resources.
Once the WARP client is configured, you can use your RDP client to connect to the server's private IP address (instead of the public IP address used initially).
To connect in Microsoft Remote Desktop:
- Open Microsoft Remote Desktop and select Add a PC.
- For PC name, enter the private IP address of your RDP server. In GCP, this is the Internal IP of the VM instance.
- For User account, enter your RDP server username and password.
- To test Zero Trust connectivity, double-click the newly added PC.
- When asked if you want to continue, select Continue.
You now have secure, remote access to the RDP server.
Was this helpful?
- Resources
- API
- New to Cloudflare?
- Products
- Sponsorships
- Open Source
- Support
- Help Center
- System Status
- Compliance
- GDPR
- Company
- cloudflare.com
- Our team
- Careers
- 2025 Cloudflare, Inc.
- Privacy Policy
- Terms of Use
- Report Security Issues
- Trademark