Cloudflare Docs
Magic WAN
Visit Magic WAN on GitHub
Set theme to dark (⇧+D)

Configure tunnel endpoints

Cloudflare recommends two tunnels for each ISP and data center router combination, one per Cloudflare endpoint. Cloudflare will assign two Cloudflare endpoint addresses shortly after your onboarding kickoff call that you can use as the tunnel destinations on your data center routers/endpoints.

To configure the tunnels between Cloudflare and your locations, you must provide the following data for each tunnel:

  • Customer edge IP address — A public Internet routable IP address that is outside of the prefixes Cloudflare will advertise on your behalf. These are generally IP addresses provided by your ISP. If you intend to use a physical or virtual connection (Cloudflare Network Interconnect), you do not need to provide edge addresses. Cloudflare will provide them.
  • Interface address — A 31-bit subnet (/31 in CIDR notation) supporting two hosts, one for each side of the tunnel. Select the subnet from the following private IP space:
    • 10.0.0.010.255.255.255
    • 172.16.0.0172.31.255.255
    • 192.168.0.0192.168.255.255
    • 169.254.244.0/20
  • Private IP addresses — The private IP address assigned to the Cloudflare and customer sides of the tunnel
Edge routing configuration example
TunnelCustomer edge IPPrivate subnetCustomer private IPCloudflare private IP
TNL_1_IAD104.18.112.7510.10.10.100/3110.10.10.10010.10.10.101
TNL_2_IAD104.18.112.7510.10.10.102/3110.10.10.10210.10.10.103
TNL_3_ATL104.40.112.12510.10.10.104/3110.10.10.10410.10.10.105
TNL_4_ATL104.40.112.12510.10.10.106/3110.10.10.10610.10.10.107

​​ Add tunnels

  1. Log in to your Cloudflare dashboard, and select your account.
  2. Select Magic WAN > Manage Magic WAN configuration > Configure.
  1. From the Tunnels tab, select Create.
  2. On the Add tunnels page, choose either a GRE tunnel or IPsec tunnel.
GRE tunnel
  1. On the Add GRE tunnels page, fill out the information for your GRE tunnel.
  2. (Optional) We recommend you test your tunnel before officially adding it. To test the tunnel, select Test tunnels.
  3. To add multiple tunnels, select Add GRE tunnel for each new tunnel.
  4. After adding your tunnel information, select Add tunnels to save your changes.
IPsec tunnel
  1. On the Add IPsec tunnels page, fill out the information for your IPsec tunnel.
  2. (Optional) We recommend you test your tunnel before officially adding it. To test the tunnel, select Test tunnels.
  1. To add multiple tunnels, select Add IPsec tunnel for each new tunnel.
  2. After adding your tunnel information, select Add tunnels to save your changes.

​​ Edit tunnels

  1. From Tunnels, locate the tunnel you want to modify and select Edit. To edit multiple tunnels, select the checkboxes for each tunnel and then select Edit selected tunnels.
  2. On the Edit tunnels page, fill out the fields you want to modify.
  3. (Optional) We recommend you test your tunnel before officially adding it. To test the tunnel, select Test tunnels.
  4. After adding your information, select Edit tunnels to save your changes.

Note that you cannot edit the Cloudflare endpoint associated with your tunnel.

​​ Delete tunnels

  1. From Tunnels, locate the tunnel you want to modify and select Delete.
  2. Confirm the action by selecting the checkbox and selecting Delete.