// how to fix
Attachments blocked or flagged as dangerous
Some file types are refused outright, large files bounce, and unexpected attachments raise spam scores. Send safe formats, keep them small, or share a link instead.
What it means
Attachments are the most common way to spread viruses by email. So receiving servers treat them carefully:
- Dangerous file types are blocked. Gmail, Outlook and most company filters refuse programs and scripts, such as
.exe,.bat,.js,.vbs,.scror.iso, even inside a.zip. - Office files with macros (
.docm,.xlsm) are often quarantined. - Encrypted archives (password-protected zip) cannot be scanned, so many filters block them.
- Large emails bounce. Many servers refuse messages above 20 to 25 MB, and attachments grow by about a third once encoded for email.
Why it matters
Your email may be refused with an error, silently removed, or delivered without the file. Even when it arrives, an unexpected attachment from an unknown sender raises the spam score and trains people to ignore you.
How to check
Delivmail checks this for you in two ways:
- Send a test email: on the home page (
/), copy your unique test address, send it a normal email from the mailbox you want to check, then open the report. Attach the same file you normally send. The SpamAssassin section shows any rules triggered by the attachment. - If a recipient gets a bounce, read it: messages such as
552 message size exceeds limitor "attachment blocked for security reasons" tell you exactly what went wrong.
How to fix it
Choose safe formats
- Documents: PDF is the safest choice. Plain
.docxand.xlsxwithout macros are usually fine. - Images:
.jpgand.png. - Never send programs or scripts by email. Put them on a download page instead.
Keep emails small
- Stay under about 10 MB in total to be safe with most receivers.
- Compress large PDFs and resize photos before attaching them.
- Do not send the same large file to a whole mailing list.
Send a link instead
For big files, many files, or newsletters, upload the file to your website or a trusted cloud drive (Google Drive, OneDrive, Dropbox) and send a link. Check that the link domain is not blacklisted at /blacklists, and prefer links to your own domain.
Make the email trustworthy
- Write a real message in the body explaining what the file is. An email with only an attachment and no text looks suspicious.
- Use a clear file name, such as
invoice-2026-041.pdf, notdocument.pdf.exeor a random string. - Make sure SPF, DKIM and DMARC pass: filters are much stricter on attachments from unauthenticated senders.
- Scan your own files with an up-to-date antivirus before sending.
Invoices and automatic emails
If your shop or billing tool sends invoices, many tools let you send a secure link to the invoice instead of an attachment. It is lighter, safer, and easier to update.
Check that it is fixed
Send the new version, with the safer file or the link, to a fresh Delivmail test address. The report should show a lower spam score and no rules about the attachment. Then send it to a colleague on another provider and confirm the file arrives intact.
Check that it is fixed
DNS changes can take from a few minutes to a few hours. Then send a new test email or scan your domain again.
Related guides
- Move DMARC from p=none to quarantine or reject safelyp=none only watches. To really stop fake emails using your domain, move step by step to quarantine and reject, without blocking your own emails.
- Your sending IP address is on a blacklistA blacklist is a public list of IP addresses known for sending spam. Find out if the IP is yours, fix the cause, then ask for removal.
- Your domain is on a blacklist (Spamhaus DBL, SURBL, URIBL)Domain blacklists list domain names seen in spam. They follow your domain wherever you send from. Find the cause, clean up, then request removal.
- Protect your incoming mail with MTA-STS and TLS-RPTMTA-STS forces other servers to use encryption when they deliver email to your domain. TLS-RPT sends you reports when that fails. Both are optional but recommended.
- Emails sent without TLS encryption (STARTTLS)Your server delivered the email in clear text, without encryption. Gmail flags this with a red padlock and expects bulk senders to use TLS. Turn on STARTTLS.