Hi Mohammad,
On 18/04/2019 10.05, Mohammad Etemaddar wrote:
Hello. I'm working on a bussiness website. I send invitation and also
confirm emails by django-allauth.
Invitation and allauth emails go to spam box.
I don't know what is the problem?
How can I prevent emails going to spam?
This is hardly related to Django, but anyway...
There is really no standard way to detect spam, for good reasons, so it
really depends on the mail server receiving the mail.
The first thing I would do would be to look at the headers for the mail
flagged as spam. Some spam scanners (eg. spamassasin) sets some
additional headers with scores it has used to determine the mail is
spam. You could use that to see what might be the cause for this mail
being flagged as spam.
It could be something as simple as the mail only having HTML content
which is not only a violation of the RFC but also one of the seven
deadly sins :-)
Apart from that, you should ensure that the host you are using to send
the mail is configured correctly. That potentially requires messing a
lot around with mail server configuration. Specifically, you should look
into things like DKIM, SPF and DMARC.
Also, make sure that the host sending the mail has a static IP. I know
that some mail servers (eg. hotmail/outlook365/whatever it's called
these days) always flags mail sent from a dynamic IP as spam, so make
sure you can get a static IP from your hosting provider (or change your
hosting provider to someone who will give you that).
If you can provide the full content (including all headers) of the mail
being flagged as spam, feel free to post it and I'll try to have a look.
Hope that helps a bit.
Kind regards,
Kasper Laudrup
--
You received this message because you are subscribed to the Google Groups "Django
users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-users/b82a7852-0256-a8ff-bfc1-0eea2576c1e2%40stacktrace.dk.
For more options, visit https://groups.google.com/d/optout.