Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

feat: auto-redirect to base path if set (#18076)

Kevin Grünebergf4eebc506156
diff --git a/studio/next.config.js b/studio/next.config.js
index 5aa6af64357..d3c0dbbc1a3 100644
--- a/studio/next.config.js
+++ b/studio/next.config.js
@@ -177,6 +177,16 @@ const nextConfig = {
destination: '/project/:ref/sql/new',
permanent: true,
},
+ ...(process.env.NEXT_PUBLIC_BASE_PATH?.length
+ ? [
+ {
+ source: '/',
+ destination: process.env.NEXT_PUBLIC_BASE_PATH,
+ basePath: false,
+ permanent: true,
+ },
+ ]
+ : []),
]
},
async headers() {