EmailFilter

Domain lists

EmailFilter keeps four lists, each a text file in the lists folder with one entry per line. Lines starting with # are ignored.

List File Matches
disposable disposable_domains.txt the domain and its parent domains
blacklist blacklisted_domains.txt the domain and its parent domains
whitelist whitelisted_domains.txt the domain and its parent domains
spam_keywords spam_keywords.txt words anywhere in the local part

Disposable domains

The list in the repository is updated every day from disposable-email-domains and has 109,392 domains. You can browse and search it on this site.

To keep it current:

  • With a git checkout, run git pull. EmailFilter notices the changed file and reloads it within a minute.
  • Without one, set EMAILFILTER_DISPOSABLE_URL=https://stefanpejcic.github.io/disposable-email-domains/domains.txt. EmailFilter downloads it at startup and every EMAILFILTER_DISPOSABLE_REFRESH (24 hours). A download much shorter than the current list is ignored.

Whitelist and blacklist

Add and remove domains through the API; the change is saved to the file and applies to the next check:

curl -X POST "http://localhost:8000/blacklist?domain=spam.example"
curl -X DELETE "http://localhost:8000/blacklist?domain=spam.example"

A domain cannot be on both lists. Whitelisting adds the whitelisted weight; it does not skip the other checks, so a whitelisted domain without mail servers can still score low.

Spam keywords

Words in spam_keywords.txt are matched anywhere in the local part, ignoring case: lottery matches biglottery.winner@…. Keep the words specific; a short word like win would also match edwin.

Editing the files directly

You can edit the files with any editor or keep them in your own git repository. EmailFilter checks them every minute and reloads the ones that changed. Writes through the API replace a file in one step, so a reader never sees half a list.

Edit this page on GitHub

Keep fake addresses out before they sign up.

Free and open source. No sign-up, no API key, no address leaves your server.

10test@mailinator.comrejectedDisposable email domain 30xkcdqwrt@nonexistent.examplerejectedNo mail servers 90john.smith@gmail.comacceptedMailbox exists, established domain