Skip to main content

Our email CSS engine is open source. Give it a star on GitHub 

Emailens

HTML Email Minifier

Gmail clips any message over 102 KB (104,448 bytes). This strips comments and whitespace, and leaves Outlook conditionals, <pre> and your CSS as they are.

@emailens/engine 0.18.22 · data last changed 10 Nov 2026

Example · the sample above. Paste yours to replace it.

−14%
110 B smaller
791 B → 681 B
1 comment removed
Before
791 B
After
681 B

After: 0.7% of Gmail's 102 KB clip limit.

minified.html
<!DOCTYPE html> <html> <head> <title>Your receipt</title> </head> <body style="margin: 0; background: #f6f4ef;"> <table role="presentation" width="100%" cellpadding="0" cellspacing="0"> <tr> <td style="padding: 24px; font-family: Arial, sans-serif; color: #111111;"> <h1 style="margin: 0 0 12px;">Thanks for your order</h1> <p style="margin: 0;">Your order has shipped and arrives Friday.</p> </td> </tr> </table> <!--[if mso]><table role="presentation" width="600"><tr><td><![endif]--> <p style="font-family: Arial, sans-serif; font-size: 12px; color: #777777;"> Acme Goods · 48 Market Street · Portland, OR 97204 </p> <!--[if mso]></td></tr></table><![endif]--> </body> </html>

Or see exactly where Gmail's clip line falls, and whether your unsubscribe link is above it: Check its size, free

The checker needs a computer screen.

Your next question

Other free tools: Subject Line & Preheader Tester · Plain-Text Generator · AI Fix-Prompt Generator · Email Link Checker · UTM Link Builder · Accessibility Checker

Run this check on every email

The open-source CLI checks every template's size, free: npx @emailens/cli lint email.html (CLI docs).

The 102 KB clipping check in the app (Dev). Dev is $9 a month. Share links for your client's sign-off, a test inbox and an API key. See the plans →

Questions

How does minifying fix Gmail clipping?

Gmail clips any email whose HTML exceeds 102 KB, hiding everything past the cut behind a 'View entire message' link, including tracking pixels and unsubscribe links. Minifying removes the dead weight (indentation, newlines, comments) that templating engines add, which is often enough to drop you back under the limit.

Will minifying break my email?

This minifier is deliberately conservative. It preserves Outlook conditional comments, the whitespace inside <pre> and <textarea> blocks, and leaves your style and script bodies untouched. It only collapses runs of whitespace and strips ordinary HTML comments, keeping single spaces so inline text spacing is intact.

Why is my email still over the limit after minifying?

If you're still over 102 KB, the weight is usually elsewhere: large blocks of repeated inline CSS, or base64-embedded images. Minifying HTML whitespace won't touch those. The fix is to consolidate repeated styles and host images on a URL instead of embedding them.

Does it minify my CSS too?

No, and that's intentional. Safely minifying CSS needs a real CSS parser, and a wrong move there can change how your email renders. This tool sticks to HTML whitespace and comments, where the savings are safe. To inline your CSS for clients that need it, use the CSS inliner.