© 2026 Hedgehog Software, LLC

TwitterGitHubDiscord
More
CommunitiesDocsAboutTermsPrivacy
Search
Star
Setup for Free
SupabaseS
Supabase•3y ago•
2 replies
Dan Syrstad

Self-hosted Reset Password Email template doesn't have the correct link

I'm self-hosting supabase via docker. I'm running supabase/gotrue:2.132.0 (also tried 2.130.0). When I initiate reset password (
/recover
/recover
) from my client app, I get the password reset email with the default template, but the "Reset Password" link is
http://localhost/auth/v1/verify?token=...&type=recovery&redirect_to=http://localhost:8167/password-reset
http://localhost/auth/v1/verify?token=...&type=recovery&redirect_to=http://localhost:8167/password-reset
. The
http://localhost/
http://localhost/
part is not correct - it is missing the port #. I have
API_EXTERNAL_URL
API_EXTERNAL_URL
set to
http://localhost:8000
http://localhost:8000
(8000 is my external port for supabase/kong), but it doesn't seem to be using it.

This started happening after I upgraded gotrue from 2.40.2 to 2.132.0 (a major bump, I know). I was on the old version for about a year and everything was working. The reset password link working fine just before the upgrade. I've been beating my head for nearly a day now trying to figure out what's happening. I've played with changing
API_EXTERNAL_URL
API_EXTERNAL_URL
to things like
https://example.com
https://example.com
, but the link always comes out
http://localhost/...
http://localhost/...
. I've scoured the gotrue source and it looks like it should be using
API_EXTERNAL_URL
API_EXTERNAL_URL
. Any tips would be much appreciated.
Supabase banner
SupabaseJoin
Supabase gives you the tools, documentation, and community that makes managing databases, authentication, and backend infrastructure a lot less overwhelming.
45,816Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

Self Hosted Password Reset Link Expired (Mimecast)
SupabaseSSupabase / help-and-questions
4mo ago
reset password email template
SupabaseSSupabase / help-and-questions
3y ago
Custom reset password email template?
SupabaseSSupabase / help-and-questions
3y ago
Reset password link expired
SupabaseSSupabase / help-and-questions
3w ago