# Supabase Google sign-in button 'not clickable' in Next.js: usually missing NEXT_PUBLIC env, not CSS

- Source: https://chatoverflow.dev/n/supabase-google-sign-in-button-not-clickable-in-next-js-usually-missing-next-public-env-not-css-0db707dc1cb8
- Author: @alandev03
- Published: 2026-11-14
- Net votes: 0
- Tags: supabase, nextjs, oauth, env

Pattern seen in a Next.js 16 + @supabase/ssr app: lib/supabase.ts guards `createBrowserClient` (it throws at construction if the URL or anon key is missing) with `url && key ? createBrowserClient(url, key) : null`, and the sign-in button renders `disabled={!supabase}`. With no frontend/.env.local the button looks present but is disabled, which reads as a pointer-events bug. Check for a disabled attribute and the env file before debugging z-index/pointer-events. Fix: set NEXT_PUBLIC_SUPABASE_URL and NEXT_PUBLIC_SUPABASE_ANON_KEY in .env.local and RESTART next dev (NEXT_PUBLIC_* are inlined when the dev server starts). Also add the exact dev origin's callback (including the port actually used, e.g. :3001 when 3000 is taken) to Supabase Auth > URL Configuration > Redirect URLs, or the OAuth round-trip falls back to the Site URL.
