Nov 26, 2026 DISPATCH // HARDWARE, CODE & PLATFORMS

Cloudflare Adds Email Gates to Free Quick Tunnels

Protected Quick Tunnels can require visitors to verify an allowed email address without a Cloudflare account or domain. Here's how to set one up and test path-based rules before Cloudflare plans to allow URL normalization by default in 2027.
Cloudflare Adds Email Gates to Free Quick Tunnels Nerds Magazine © nerdsmagazine.com
Cloudflare Adds Email Gates to Free Quick Tunnels © nerdsmagazine.com

A path rule that protects /admin may miss a disguised path such as //admin when URL normalization is off. If the local application cleans that path before routing it, the admin page could still be served. Cloudflare's October changes make this worth testing when sharing a development server.

Protected Quick Tunnels arrived on October 2, 2026. They let an operator require visitors to verify an allowed email address with a one-time PIN, without a Cloudflare account, a domain, or a charge. A Quick Tunnel still uses a temporary public URL, so it suits short demos and tests rather than persistent services.

Understand the access and version changes

Cloudflare Tunnel is available on every plan, with 1,000 named tunnels included per account. Cloudflare's October 16 changelog also raised the default route limit from 1,000 to 50,000 per account. Tunnels for Platforms include 1,000 tunnels; each additional tunnel costs $4.50 per month.

Use cloudflared 2026.10.2 or newer. Cloudflare released that version on October 20 as a security update following the eMudhra certificate compromise and advised Tunnel users to upgrade. A separate PHP patch left unsupported websites without fixes for older versions, as described in this PHP security update report.

Version 2026.10.0 introduced optional URL normalization. In 2026.10.x it is off by default. Cloudflare says new cloudflared releases will turn it on by default on January 25, 2027. The connector normalizes paths for ingress-rule matching; it does not rewrite the path forwarded to your application.

A Quick Tunnel starts as one process and gets a random trycloudflare.com address. Its URL changes on restart and stops working when the process ends. A named tunnel has a stable identity, uses your hostname and configuration, and requires a Cloudflare account plus a domain whose DNS is managed by Cloudflare. Both modes connect outward to Cloudflare, so you do not need to forward a router port.

Build the origin and start a protected Quick Tunnel

For this lab, use Ubuntu 24.04 LTS or a current macOS release, Node.js 20 LTS or newer (22 LTS is recommended), and an email account you can read. The Docker step needs Docker Engine with Compose v2; the path probe needs curl 8.x with --path-as-is. Only the named-tunnel steps require a Cloudflare account and managed domain.

On Debian or Ubuntu, install from Cloudflare's package repository. On macOS, use Homebrew. Then check the installed version; use which -a cloudflared if an older installation appears first on your path.

sudo mkdir -p --mode=0755 /usr/share/keyrings
curl -fsSL https://pkg.cloudflare.com/cloudflare-main.gpg | sudo tee /usr/share/keyrings/cloudflare-main.gpg >/dev/null
echo 'deb [signed-by=/usr/share/keyrings/cloudflare-main.gpg] https://pkg.cloudflare.com/cloudflared any main' | sudo tee /etc/apt/sources.list.d/cloudflared.list
sudo apt-get update && sudo apt-get install -y cloudflared

Create a Node HTTP origin in server.js with a /health check, /public/hello route, /admin route, and POST /webhook receiver. The lab origin should collapse repeated slashes and resolve dot segments so you can observe how its routing interacts with ingress matching. Put {"type":"module"} in package.json.

Bind the local server to 127.0.0.1 by default. Start it with node server.js, then check the health route and public route from another terminal. Send a sample webhook with:

curl -s http://127.0.0.1:8080/health
curl -s http://127.0.0.1:8080/public/hello
curl -s -X POST -d '{"event":"ping"}' http://127.0.0.1:8080/webhook

Start an unprotected Quick Tunnel with cloudflared tunnel --url http://localhost:8080. The logs provide a random public address. Anyone who gets that URL can reach the origin, so treat it as a bearer secret. Cloudflare describes Quick Tunnels as development tools; its documentation reportedly lists a limit of 200 in-flight requests and no Server-Sent Events support. Check current documentation before relying on either limit.

Stop the process with Ctrl+C. To require email verification, restart it with cloudflared tunnel --url http://localhost:8080 --allowed-mail alice@example.com. Visitors prove ownership through a one-time PIN delivered by Cloudflare Access. Neither the operator nor visitor needs a Cloudflare account. Check cloudflared tunnel --help for the exact syntax for multiple addresses or an email area.

Test the URL from a client without an authenticated session. A command-line request should reach the Access login flow rather than the application. Open the URL in a browser, enter an allowed address, and use the PIN; an address outside the allow-list should not grant access. The gate ends when the connector stops, and the next Quick Tunnel has a new URL. This is a convenience for human visitors, not a substitute for protecting real customer data.

A script can launch the tunnel and print its URL. Save the following as share.sh, make it executable with chmod +x share.sh, and run ./share.sh 8080 you@example.com. It waits up to 30 seconds for the URL and prints the log if none appears.

#!/usr/bin/env bash
set -euo pipefail
PORT="${1:-8080}"
ALLOWED="${2:?usage: share.sh PORT you@example.com}"
LOG="$(mktemp)"
cloudflared tunnel --url "http://localhost:${PORT}" --allowed-mail "${ALLOWED}" >"$LOG" 2>&1 &
PID=$!
trap 'kill "$PID" 2>/dev/null || true; rm -f "$LOG"' EXIT
URL=""
for _ in $(seq 1 30); do
  URL="$(grep -oE 'https://[a-z0-9-]+\.trycloudflare\.com' "$LOG" | head -n1 || true)"
  [ -n "$URL" ] && break
  sleep 1
done
if [ -z "$URL" ]; then echo "no tunnel URL after 30 seconds, log follows" >&2; cat "$LOG" >&2; exit 1; fi
echo "Tunnel: ${URL}"
echo "Allowed: ${ALLOWED}"
wait "$PID"

Email PIN protection blocks automated webhook providers because they cannot complete the login. Options include a brief unprotected test window, replaying a saved payload yourself, or using a named tunnel with a narrowly scoped Access bypass for /webhook. Verify the provider's signature before trusting any webhook body.

Use Docker or a named tunnel for longer-lived access

In Docker Compose, the origin must bind to 0.0.0.0; the connector reaches it through the Compose service name, not localhost. Set ALLOWED_MAIL before starting the stack. Pin the image to a verified version and confirm that its tag exists.

services:
  app:
    image: node:22-alpine
    working_dir: /srv
    volumes: ["./:/srv:ro"]
    environment: {HOST: "0.0.0.0", PORT: "8080"}
    command: ["node", "server.js"]
    restart: unless-stopped
  tunnel:
    image: cloudflare/cloudflared:2026.10.2
    command: tunnel --no-autoupdate --url http://app:8080 --allowed-mail ${ALLOWED_MAIL}
    depends_on: [app]
    restart: unless-stopped

Run docker compose up -d and inspect the tunnel logs for the URL. A restarted Quick Tunnel gets a different address. Shut down the stack with docker compose down.

For a stable hostname, authenticate and create a named tunnel, then route DNS to it. The create command returns a tunnel UUID and writes a credentials JSON file.

cloudflared tunnel login
cloudflared tunnel create lab-tunnel
cloudflared tunnel route dns lab-tunnel lab.example.com
cloudflared tunnel list

Create the Cloudflare Access application for lab.example.com before completing the protected ingress rule; the application supplies the audience tag. Replace the sample UUID, credentials path, team name, and audience tag in this configuration with your own values.

tunnel: 6ff42ae2-765d-4adf-8112-31c55c1551ef
credentials-file: /home/you/.cloudflared/6ff42ae2-765d-4adf-8112-31c55c1551ef.json
ingress:
  - hostname: lab.example.com
    path: ^/admin
    service: http://localhost:8080
    originRequest:
      access:
        required: true
        teamName: your-team-name
        audTag:
          - PASTE_THE_APPLICATION_AUD_TAG_HERE
  - hostname: lab.example.com
    service: http://localhost:8080
  - service: http_status:404

Ingress rules are evaluated from top to bottom, so put the narrow /admin rule before the hostname catch-all. The final rule without a hostname supplies the default 404; a configuration without it fails validation. In the Zero Trust dashboard, make a self-hosted application for the /admin path and attach a policy that allows your email. The team name comes from your Zero Trust team area. A wrong team name or audience tag causes the connector to reject requests to the protected rule.

For webhooks, use a separate Access application or policy that bypasses authentication only on /webhook, and retain signature verification in the handler. Run the tunnel with cloudflared tunnel run lab-tunnel. Access checks then apply at Cloudflare's edge and inside the connector.

Probe path behavior with curl's --path-as-is option so the client does not tidy dot segments before sending them. Test /admin, //admin, /./admin, /public/../admin, /public//../admin, and /public/hello. With normalization off, the illustrative lab results are 403 for /admin and 200 for the disguised admin paths and public route. These are expected examples, not live measurements; any 200 on an admin-shaped path is a finding.

Allow normalization with the flag before run, or set the environment variable on every connector replica and restart it:

cloudflared tunnel --disable-path-normalization=false run lab-tunnel
# Or, on each replica:
export TUNNEL_DISABLE_PATH_NORMALIZATION=false
cloudflared tunnel run lab-tunnel

With normalization enabled, the expected lab result is 403 for /admin and its disguised variants, and 200 for /public/hello. A mixed fleet can return inconsistent results if some replicas lack the setting. Normalization affects rule matching only; the origin still receives the client's path. Check whether legitimate clients send doubled slashes if they begin receiving 403 responses.

On Linux, copy the configuration and credentials into /etc/cloudflared/, update the credentials path, then install and allow the service. Use a systemd override to retain normalization across restarts.

sudo mkdir -p /etc/cloudflared
sudo cp ~/.cloudflared/config.yml ~/.cloudflared/*.json /etc/cloudflared/
sudo sed -i 's#/home/you/.cloudflared#/etc/cloudflared#' /etc/cloudflared/config.yml
sudo cloudflared service install
sudo systemctl allow --now cloudflared
sudo systemctl edit cloudflared

Add [Service] and Environment=TUNNEL_DISABLE_PATH_NORMALIZATION=false to the override, then restart the service and inspect its logs. Keep credentials JSON out of version control. After connector upgrades, rerun the path probe; Cloudflare's stated January 25, 2027 default change makes that check especially related to the topic for path-gated hostnames.

Topics:
Developer Tools Cloud Computing Tech Guides #Software Alternatives #Node.js #Webhooks #Docker #Security Updates
Evan Solberg Editor Nerds Magazine
Co-Founder

Evan Solberg

Evan Solberg is the Co-Founder of NerdsMagazine, where he covers consumer technology, software, artificial intelligence, privacy, and digital products. His approach focuses on what technology actually does for readers, what it costs, where it falls short, and which claims deserve closer scrutiny.