Skip to content

Commit 57c9576

Browse files
Mlaz-codepaperclip-resolver[bot]
andauthored
fix(seo): add trailingSlash to vercel.json for edge 308 redirects (#239)
The Next.js trailingSlash config only affects build output (generating en/index.html vs en.html). Vercel static hosting still serves both /en and /en/ as 200 without redirecting. Adding trailingSlash: true to vercel.json makes Vercel enforce 308 /en → /en/ at the edge, so Semrush sees a single canonical URL form. Also updates root redirect / → /en/ to avoid double redirect. Co-authored-by: paperclip-resolver[bot] <3736210+paperclip-resolver[bot]@users.noreply.github.com>
1 parent 6d7378c commit 57c9576

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

vercel.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"redirects": [
88
{
99
"source": "/",
10-
"destination": "/en",
10+
"destination": "/en/",
1111
"permanent": true
1212
},
1313
{
@@ -189,5 +189,6 @@
189189
"source": "/ingest/:path*",
190190
"destination": "https://us.i.posthog.com/:path*"
191191
}
192-
]
192+
],
193+
"trailingSlash": true
193194
}

0 commit comments

Comments
 (0)