All Questions
Tagged with supabase authentication
113
questions
14
votes
1
answer
7k
views
How to implement anonymous authorization using Supabase?
Is there a way to implement anonymous authorization using Supabase?
I have a mobile app and I want to implement the following functionality:
Every user should have an account on the server right after ...
5
votes
2
answers
4k
views
Supabase signInWIthPassword is giving me a 502 error
All auth functions work except signInWithPassword using React, TypeScript, and Supabase.
My context: It allows me to signIn, create a profile and move on. I am able to getUser() during the session ...
5
votes
2
answers
3k
views
How to change the redirecting url for Google OAuth with supabase?
I am trying to set up a website with supabase using Google OAuth for authentication.
It's fairly easy and convenient to set up and works really well, by following this tutorial and consulting the docs....
4
votes
1
answer
2k
views
Cannot destructure property 'supabaseUrl' of 'getConfig(...)' as it is undefined
I followed @supabase/auth-helpers-sveltekit guide on how to integrate supabase-auth helpers with sveltekit.
Yet, when running the dev server, I get an internal error
Cannot destructure property '...
4
votes
1
answer
412
views
Supabase Auth UI: show the sign up UI not the sign in UI?
I am using Supabase Auth UI as the login / sign up auth provider for my website.
Currently the Auth UI always shows the login button. I can get onto the sign up UI by clicking "Don't have an ...
4
votes
0
answers
963
views
Supabase SSR getSession always returns null
I've tried to check for session on server side in my NextJS project. I've used supabaseService client and also "createServerSupabaseClient" from @supabase/auth-helpers-nextjs both of those ...
3
votes
1
answer
123
views
Act on Behalf of GitHub User With Supabase Auth
I have a JavaScript browser app, and a ASP .NET Core Minimal API backend. The database is Supabase and the user authenticates with the GitHub Supabase auth provider.
The app, whether backend or ...
3
votes
2
answers
2k
views
supabase auth.uid() = user_id equals false
I have a very strange problem that is driving we up the walls.
I am creating the following table
CREATE TABLE articles(
id BIGINT generated by default as IDENTITY PRIMARY KEY,
user_id uuid ...
3
votes
3
answers
1k
views
How to implement cookie authentication with Sveltekit & Supabase?
I'm fairly new to both SvelteKit & Supabase and have done a bit of experimentation on my own, but I would like to know what is the best way to implement user authentication with both of these ...
3
votes
1
answer
2k
views
How to sign in with Apple and Google credentials in react-native and supabase
I have been trying to implement sign in with google and apple using the following libraries and supabase in bare react-native projects.
react-native-apple-authentication
react-native-google-signin
...
2
votes
2
answers
3k
views
How to use the signUp() method in Supabase to add additional user info when signing up
I am attempting to build a Vue.js application that includes authentication with Supabase. I wish to use the built-in Supabase signUp() method to handle additional user data when signing up. To do this,...
2
votes
1
answer
2k
views
How to check if a user is signed in with Supabase in SvelteKit?
I am working on a SvelteKit application and using Supabase for user authentication. I have implemented the sign-in functionality in my /signin/+page.server.ts file using the supabase.auth....
2
votes
2
answers
1k
views
Flutter and Supabase - OAuth deep link not working
I have set up OAuth with my Flutter app and Supabase. It works on the web... I sign in to the provider and I'm redirected to my website with the credential. However, in iOS, it does not work. I sign ...
2
votes
1
answer
3k
views
How to customize supabase email?
My application leverages supabase's magic link for user authentication.
It works great but the email looks pretty basic. That's what it looks like:
Is there a way to edit this email template?
I'd ...
2
votes
1
answer
643
views
Same google clientId and clientSecret for multiple devices (andorid, ios and web)
I am developing an application using Supabase, Flutter and Google OAuth and I would like to know if it is possible to have a single clientId and clientSecret for each device type (ios, android and web)...
2
votes
1
answer
374
views
How can I stop the infinite loop in my React supabase Authentication?
I have two files a "Home" and a "LoginPage". The defined routes are that "/" goes to LoginPage and "/home" goes to Home. When I try to login using the Auth ...
2
votes
1
answer
4k
views
Database Error Saving New User error with Postgres Function?
For my website (backend support by Supabase), I have the built-in auth.users table, and a public.profiles table that includes text fields for email, username, and school. I have created a trigger and ...
2
votes
0
answers
434
views
How to configure supabase to use a http cookie to store the session?
I'm currently storing the old access and refresh token inside a http only cookie from a Next JS route handler that I can recall to set the previous session again (which I do in the middleware), ...
2
votes
1
answer
211
views
How to use a custom ConfirmationURL with @supabase/auth-ui-react?
I'm building a React app with the Auth component from @supabase/auth-ui-react, and I want to take the user to a specific path after they click the email confirmation link on signup.
Is there any way ...
2
votes
1
answer
2k
views
Redirect user after sign in in supabase and next js 13
I'm migrating to next js 13 and I'm wondering how can I perform a redirect after the user signs in with email and password. Currently, the session and user are returning well, but if I router.push('/')...
2
votes
0
answers
608
views
google provider sign in with supabase auth
sigining in with next_auth and a google provider sends me to the "site URL configuration" setting.
(the main site URL)
with an access token at the end of the URL.
Siging in on the same page ...
2
votes
2
answers
2k
views
nextjs-ts-user-management, how to handle redirect to login page using @supabase/auth-helpers-nextjs?
TLDR:
I'm leveraging https://github.com/supabase/supabase/tree/master/examples/user-management/nextjs-ts-user-management
to build basically a TODO/hello world app and it's amazing. But you will notice ...
1
vote
1
answer
3k
views
Supabase: problem with login with Flutter
I'm trying to login to the Supabase using password:
final supabaseClient = SupabaseClient('supabaseUrl','supabaseKey');
final response = await supabaseClient.auth.signInWithPassword(email: '...
1
vote
3
answers
343
views
Configuring Environment-Specific Redirect URLs in Next.js with Supabase Auth
I am developing a Next.js application with Supabase authentication. In my Supabase settings, the 'Site URL' is set to https://some-production-url.com for the production environment. However, for local ...
1
vote
1
answer
2k
views
Supabase login error: auth.signIn is not a function
I am trying to log in via Supabase and get the error:
react_devtools_backend.js:2655 Error: _supabaseClient__WEBPACK_IMPORTED_MODULE_2__.default.auth.signIn is not a function
overrideMethod @ ...
1
vote
1
answer
2k
views
supabase delete user through application
I have a supabase project where I want the users to be able to delete their account.
Every user has a profile in public.profiles. I thought I could let the users delete their profile and then handle ...
1
vote
2
answers
2k
views
How can I update data when user confirms email? Supabase Nextjs
I would like to update my profiles table once my user signs up with a magic link.
Here is my current code:
Login.tsx
import { useState } from "react";
import { supabase } from "../lib/...
1
vote
2
answers
544
views
Authenticated user shows up in console.log but can't access the object
I'm using Supabase for authentication and I get a user object when logging in.
This is how it looks like:
{
"id": "cb43b195-22cc-48c8-946a-d323f70165bd",
"aud": "...
1
vote
1
answer
157
views
React Router Dom v6 does not mantain Context (Supabase)
I created the skeleton of my app, with vite + react and supabase.
I set all the routes and created a context to understand if a user is logged in or not.
the context checks the localstorage if the ...
1
vote
1
answer
637
views
How to get/update is_super_admin in the auth.users table
I would like to use the is_super_admin column in the auth.users table. However, I cannot find any way to query its value in React.
I have tried both
supabase.auth.getUser()
and with service role ...
1
vote
0
answers
55
views
React Native Expo Facebook Auth with Supabase and react-native-fbsdk-next: Nonces Mismatch
I'm trying to implement Facebook authentication in a React Native Expo app using Supabase and react-native-fbsdk-next. I'm currently following the Google auth implementation guide provided by Supabase ...
1
vote
0
answers
56
views
supabase.Auth.CurrentSession returns null , c# client
I'm using dotnet add package supabase-csharp as a c# client.
I'm signed in var session = await supabase.Auth.SignIn(email, password); successfully, but when i tried to get the current user or session ...
1
vote
0
answers
76
views
Supabase Auth not working unless application is refreshed
I'm currently using supabase auth for users to sign in and sign out into an application I'm working on. I have this simple function that handle signing in:
const signIn = async (email: string, ...
1
vote
2
answers
335
views
Supabase auth not storing anything in cookies sveltekit
I am trying to build a simple supabase application, I have followed the documentation for the "auth" section exactly, as far as I can tell. Currently, I am generating a magic link, getting a ...
1
vote
1
answer
165
views
useSupabaseClient() returns undefined
I'm currently following Antonio's Spotify clone tutorial (at 2:08:00), but I've hit a stumbling block, useSupabaseClient() returns undefined, which causes this line <Auth supabaseClient={...
1
vote
0
answers
248
views
Trouble with webhook check in self-hosted Supabase/GoTrue for authentication
Recently, I attempted to self-host Supabase/GoTrue for authentication purposes. However, I encountered a problem with the webhook check, which prevented me from proceeding. Now, I have a question: Do ...
1
vote
0
answers
332
views
Flutter Supabase has problem to handle the onAuthStateChange event with dynamic widget
Hello I am currently looking to change my project to supabase with real SQL.
In my firebase project I had an Checker which checks the current authstate which always returns a User?.
Now I try to ...
1
vote
0
answers
702
views
Using VUE.js, pinia and supabase. How can I get the info of the user currently logged in
This is a novice question.
//auth.js (pinia store)
import { defineStore } from 'pinia'
import supabase from '../supabase'
import {ref, watch} from 'vue'
export const useAuthStore = defineStore('user'...
1
vote
0
answers
106
views
Unable to retrieve session state when navigating from login to homepage
I'm following a course on undemy and have hit a wall. I have been able to implement a login page and authentication. However once I navigate away from the login page, I see that session data is not ...
1
vote
2
answers
644
views
Is it worth caching auth session in client-side state?
I have a React app which uses Supabase for authentication.
I'm wondering, is it best practice to store a user's session in client-side state (e.g. setState or the like) in order to avoid making an API ...
1
vote
1
answer
280
views
How to send a "password reset" email from Swift with Supabase?
I try to rest passwords for users in my swift application. I'm using Supabase as backend. How I can trigger the send?
In Java or Flutter it's like:
supabase.auth.resetPasswordForEmail(
'sample@email....
1
vote
2
answers
2k
views
User needs to refresh the page to get logged in after third party authentification (Supabase, NextJS)
I'm using supabase with next and third party auth. The problem is that my user has to refresh the page to get logged in after using third party auth. I have tried getting the user's data from the ...
1
vote
1
answer
1k
views
supabase auth-helpers-nextjs package not working properly
I am using supabase auth helper package in my project. When the user enters the login details it should be redirected to the order page. I am using supabase auth condition in the order page. But when ...
1
vote
1
answer
2k
views
How do I recover the reset password token from Supabase in React?
I'm a new developer and this is my first time posting to Stack Overflow
I'm using supabase for my db and authentication on my React app. I'm trying to integrate their 'Reset Password' feature (which ...
0
votes
2
answers
2k
views
How to create a reuseable protected route in Next.js
I'm new to Next.js. I'm presently using Supabase magic links for auth. Based on this awesome tutorial, I made one of the pages on my app a protected route. I did this by adding the following code to ...
0
votes
1
answer
546
views
Resetting Password with React Native, Supabase, and Auth Flow
I've been having trouble resetting the password in my React Native app that uses Supabase and an auth flow. The App function uses the useUser hook to retrieve a Boolean value called AppStacktrue. If ...
0
votes
2
answers
357
views
configure db authentication to allow sign up only to known email addresses
I want to build an app (in react js) for myself, my family, and some close friends (+/- 40 people). But having this app live, anyone could go on the apps web address and submit a sign up form, and yes ...
0
votes
1
answer
152
views
How to authenticate users with social logins in web widget?
I have a web widget which other users can embed on to their own websites. The widget is built with vanilla JS and no external libraries, whilst I'm using a node.js backend.
And the widget requires ...
0
votes
1
answer
35
views
Can't listen for signUp and EmailRegistration events on Supabase in Flutter
I'm trying to catch a user register and email confirmation event.
In the register page, I have supabase.auth.onAuthStateChange event listener that redirects them to another screen saying to click on ...
0
votes
1
answer
24
views
Supabase user data not loaded on time when app is loaded so I get null
So in my React Native app, I have screen that grabs user data and pass it to sub components.
However, the code gives the below error which seems it is not rendered before the screen OR maybe it is ...