Skip to content

🐛2026.8.1: path canonicalization still percent-encodes parentheses — incomplete fix for #1717 #1719

Description

@angga-syah

Title: 2026.8.1 percent-encodes parentheses in request path, breaking Next.js route groups

Describe the bug

cloudflared 2026.8.1 percent-encodes ( and ) in the URL path before
forwarding to the origin. 2026.7.3 forwards them unencoded.

Per RFC 3986 these are sub-delims and are valid unencoded in path segments.
Next.js App Router "route groups" produce real on-disk directories named
(auth), so the re-encoded path no longer matches and returns 404.

Reproduce

Origin serves a file at:
/_next/static/chunks/app/(auth)/login/page-.js

Request through the tunnel with either the raw or pre-encoded form.

Origin access log:
2026.7.3 -> "GET /_next/static/chunks/app/(auth)/login/page-.js" 200
2026.8.1 -> "GET /_next/static/chunks/app/%28auth%29/login/page-.js" 404

Requesting the file directly at the origin (bypassing the tunnel) returns 200
on both versions, so the origin is not at fault.

Expected

Path forwarded unchanged, as in 2026.7.3.

Actual

Parentheses percent-encoded; origin 404s.

Environment

cloudflared 2026.8.1 (docker, cloudflare/cloudflared:latest)
Origin: nginx -> Next.js 16 standalone
Regression from 2026.7.3 (works)

Impact

Breaks every Next.js App Router site using route groups — the login page
fails to load its JS chunk.

Pinned by jcsf

Metadata

Metadata

Assignees

No one assigned

    Labels

    Priority: NormalMinor issue impacting one or more usersType: BugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions