Anvil doesn’t send emails anymore, even though I have more than 90.000 left. I didn’t set up a custom mail server and didn’t change everything. Everything worked until about 3 hours ago.
Now when I execute the following code (or code similar to it), nothing happens. No crash either.
anvil.email.send(from_name = "My App Support",
to = "[redacted]",
subject = "Welcome",
text = "Welcome to My App!")
Note: This is only the case with one app of mine. Another app works fine. Will DM a link to the non working app to any mod or admin of course.
Update: Doesn’t seem to be related to apps but to recipient emails. I’m unable to send emails to hotmail addresses and to at least one other domain from my anvil app. I don’t get any error message in the code or “message can’t be delivered” email. Please help!
Note: We have replied directly to avoid sharing private customer information in a public forum post. The issue was emails being blocked by a spam filter at the receiving end.
I’m afraid there’s not much we can do about this - you will need to unblock emails from your app at the recipient. It may help to switch to a custom domain, and make sure you have DKIM set up.
I would recommend setting up DKIM as linked in my previous post, then you give your messages the highest chance of being delivered. If they still don’t get through, that’s something you’ll need to fix at the receiving end where they’re being blocked.
Sorry, maybe it is unclear to me.
I am using the default code to send email as below, what can I change to unblock or to fix. I do not see any error from app log
This means that all emails sent via Anvil’s own server (without setting up your own SMTP server in the email settings of your app) have a high likelihood from being rejected by many different networks.
I set Anvil to use my own SMTP server instead of the built in one which fixed the issue described above but now I get this error message whenever a user tries to reset his password: