-
-
Notifications
You must be signed in to change notification settings - Fork 13
Open
Labels
bugSomething isn't workingSomething isn't working
Description
I’m experiencing an issue where realtime updates are not received on the first page load when using createBrowserClient (e.g. from @supabase/ssr or @supabase/auth-helpers-nextjs) in Next.js.
The connection appears to be established (channel subscribes without error), but no events are delivered until I navigate away and return (for example, visiting a detail page and then going back).
Reproduction Steps
- Use createBrowserClient in a global provider or page component.
- Subscribe to postgres_changes for a table via:
supabase .channel('my-channel') .on( 'postgres_changes', { event: '*', schema: 'public', table: 'my_table' }, (payload) => console.log(payload) ) .subscribe();
- Load the page — no realtime updates are received when the database changes.
- Navigate to another page (e.g. /detail/[id]) and then return to the original page.
- Updates begin to arrive as expected.
Expected Behavior
Realtime updates should start arriving immediately upon subscription on the first page load
Environment
- @supabase/ssr: ^0.6.1
- @supabase/supabase-js: ^2.54.0
- next: ^15.3.2
- Client creation method: createBrowserClient from @supabase/ssr
- Setup: Supabase Realtime is enabled on the table in the dashboard.
asrouji, masaok and Fundstatapp
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working