fluttersupabase

How can I create a user in Superbase and remove email authentication?


I'm trying to make a easy login function. A user creation works, but users need to verify their email to use it. So this is not easy and complicated.

await Supabase.instance.client.auth.signUp(email: email, password: password);

So I thought of a way to add it directly to the users table of the auth schema by next code.

await Supabase.instance.client.from('auth.users').upsert({'email': email, 'password': password});

But I cannot use other schemas but public because public. is automatically pasted before the table, you cannot use other schemas. (public.auth.users)

Please advise me how to forcibly add and activate users without email authentication.


Solution

  • If you want to register a user without having them confirm the email address, you can just turn off the Confirm email setting from your Supabase dashboard under Authentication > Providers > Email > Confirm email.

    Supabase dashboard