why verification mail, forgot password mails are taking too long to reach to users sometimes?
when users are creating account, the verification emails from supabase is taking too much time to reach to users (approx. 5-6 min). Where as sometimes it coming quick like usual it should be, sane thing happening with forgot password too. Please help asap, the problem is encountered on both live site and local host .
50 Replies
and sometimes its saying email rate limit exceeded.
have you enabled a custom smtp or are you using supabase for sending this emails?
yes custom smtp is enabled
you might have to reach out to you smtp provider then to see if there are any issues
which smtp are you using? Do they provide details themselves of logs or when emails are sent?
sendgrid
rate limit is enabled by default to protect your SMTP from abuse
You can change the limits from your supabase dashboard
actually this is a client project i am working on, and he said to use sendgrid, and he sent me an api key to use
please guide, from where i can fix this issue
i think the API key is only for use in edge functions, you would need access to Auth -> emails -> smtp settings to investigate login related issues
https://supabase.com/dashboard/project/_/auth/rate-limits
Check your project's logs, if the log entry shows that the email was sent then its an issue with your smtp
and from where i can see the logs?
For example, this is for magic-link


You need to check with your SMTP. everything is fine here
Also you can test with the supabase's inbuilt SMTP for testing one or two emails
like the smtp was just enabled few days back, but this issue was from starting
even with inbuilt smtp?
a minute or 2 delay is normal
it was like 5-6 min approx
?
yupp
thats strange. I just tried with inbuilt one and got an email within a minute
Try sending email from dashboard to your email address with the inbuilt one
direct link plz
https://supabase.com/dashboard/project/_/auth/users
Select the email and a side menu on the right side will open. There you'll find an option to either send magic-link or reset-pass

It's email rate limit exceeded msg
so this rate limit is supabase thing?
and delay emails are from sendgrid?
correct
This is where you adjust these rate-limits
okay thankyou, boss. Now i need to guide that dumb client, that his sendgrid thing is causing the issue not supabase
Did you try sending emails with inbuilt smtp?
There is a rate limit on the inbuilt one that is not customizable
But its fine for testing 1 or 2 emails
so like this is a production level site, ao how can we deal with that?
You can't. custom smtp is the way to go
You can try brevo or resend. resend has a free plan. not sure about brevo. You can use that to guide your client that its an issue with sendgrid
okay thankyou, i will
brevo too has a free plan
no he just want to use sendgrid, dont know why
Just for demo purposes, you can use the inbuilt one or set up a free account on either resend or brevo and use that. On resend, until you verify your domain with them you can't send any emails to addresses other than your own email. keep that in mind. don't know about brevo.
this site is going to launch tomorrow, so we don't have time to test or demo thing, we have to fix it from what we are using
What I meant was to show your client that its your sendgrid smtp which is causing issues and they will need to use some other SMTP
so you are saying that it cant be fixed from sendgrid side too??
ther email delay thing
I've never used sendgrid but no email provider voluntarily delays sending emails. Maybe too much load on their systems
scheduling emails is a different thing
okay lets see, whats happening on sendgrid side, i have also never used that, just working with api key only, let me get the developer access of sendgrid from them and hope that this thing get fixed
If the client is fussy, you're gonna have to show a demo with another provider
otherwise its your fault
okay i will keep your alternatives suggestion in mind,
lets hope its not 🥲
i mean if the problem is from code, then every email should get delayed, why some of them are getting delayed
do you see the same delay when sending mail from dashboard?
no, from dashboard it was only limiting, from sending it too frequently
You can change the limits and retry
Do you know how to setup a server?
i have only developer access, and to edit or chnage those it require admin access
There is open source test smtp server mailpit which can be used to receive emails
i am an intern here, and got my degree this year only, dont expect much from me🥲
like nodemailer ?
nodemailer is a client which sends emails. mailpit is a smtp server which receives those emails but instead of forwarding to the email address it stores emails
https://www.youtube.com/watch?v=PJo5yOtu7o8
inder bhai you are too helpful yaar,
india?
me Up (lucknow)
i have to inform the client about this smtp (sendgrid ) issue, let see what he says, and then i will get back to you
thankyou for your valuable time, for teaching me. 🫡 really appreciate your patience
no worries