Hacker News new | ask | show | jobs
by pravus 1037 days ago
I recently set up my own self-hosted email solution again and made sure to do all of these things:

    * Proper A and MX record set up in DNS per SMTP standards
    * Proper SPF record in DNS
    * Proper DMARC record in DNS
    * Proper DKIM record in DNS
    * SMTP server (postfix) is not configured as an open relay
    * SMTP server is configured with a DKIM milter to sign outgoing messages
I used basic guides for the DMARC/DKIM stuff since that was new to me and tested with a Gmail account. The first few messages were marked as spam but I was able to unmark them. Once I was able to verify a correct SMTP setup, after two or three unmarkings, all messages were just delivered normally and no longer marked as spam. Google will even email you a report to help debug issues if your DMARC record is set up for it.

As far as I know this is about the best you can do. Everything else is pretty much getting your mail server IP addresses removed from various blacklists which can be easy to impossible depending on the service. The other option would be to forward to another service that allows relaying and has IP addresses with better spam scores but I personally prefer to avoid that.