# Spam, viruses, retention and quotas

> What is filtered before it reaches an inbox, how long mail is kept, and how much space each inbox has.

Applies to: the Sypnia engine (open source, self-hosted) and Sypnia Cloud (paid service).  
Source: https://mail.docs.sypnia.com/mailboxes/filtering-and-retention/

For agents: Mail mailboxes filtering: every incoming message is checked for SPF, DKIM, DMARC, spam and viruses; viruses are dropped and the sender gets nothing; spam goes to the Spam folder (kept 30 days); allow and block lists per inbox and per domain; reports from people (Not spam / Spam) train per-domain rules. Retention: messages kept until deleted; Trash and Spam emptied after 30 days. Quotas: storage per inbox by plan; attachments up to 25 MB sent / 30 MB received; extra storage prepaid in credits; at 90 % a warning, at 100 % new mail bounces with a clear message.

## Before a message reaches an inbox

Every incoming message is checked:

| Check                | What happens                                                                                                 |
| -------------------- | ------------------------------------------------------------------------------------------------------------ |
| **SPF, DKIM, DMARC** | Messages that fail the sender's own DMARC policy are treated as the sender asks: rejected or marked as spam. |
| **Viruses**          | Dropped. Nobody receives them and the sender gets no answer.                                                 |
| **Spam**             | Moved to **Spam**, where it stays 30 days.                                                                   |

Each inbox and each domain has **allow and block lists**. When people mark a message as _spam_ or _not spam_, that teaches the domain's own rules; it never changes how another customer's mail is filtered.

## Retention

Messages stay until someone deletes them. **Trash** and **Spam** empty themselves after 30 days.

## Space

Each inbox has a storage quota set by the [plan](https://mail.docs.sypnia.com/cloud/plans). More space is bought per item, prepaid in credits. At 90 % the inbox owner and the admins are warned; at 100 % new mail is returned to the sender with a clear message, never lost silently. Attachments can be up to 25 MB when sending and 30 MB when receiving.
