Feature Request: Built-in Phone Number Recycling Support for Authentication #35948
Unanswered
leonaburime-ucla
asked this question in
Feature Requests
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Problem
When phone numbers are recycled (old number assigned to new person), Supabase Auth prevents linking the recycled number to a new user account, showing the error:
AuthApiError: A user with this phone number has already been registeredThis creates a poor user experience where legitimate users cannot verify their phone numbers simply because the number was previously owned by someone else.
Current Workaround
The current solution requires:
Proposed Solution
Supabase could implement built-in phone number recycling support with one of these approaches:
Option 1: Automatic Unlinking After Successful OTP Verification
When a user requests OTP for a phone number already linked to another account
Allow OTP to be sent (perhaps with a flag indicating potential conflict)
After successful OTP verification, automatically unlink the phone from the previous account and link to the current user
This proves the new user has control of the phone number
Option 2: Configuration Option for Phone Number Uniqueness
Add a project setting to disable strict phone number uniqueness
Allow multiple users to have the same phone number temporarily
Provide hooks/triggers for custom conflict resolution
Option 3: Built-in Phone Number Recycling API
New auth methods like auth.requestPhoneRecycling() and auth.verifyPhoneRecycling()
Handle the unlinking logic internally after OTP verification
Use Cases
Users getting new phone numbers that were previously used
International users where phone number recycling is common
Business applications where phone verification is critical
All reactions