• Sp chevron_right

      What is Gmail clipping and what to do about it

      pubsub.slavino.sk / spam_resource · Wednesday, 12 January, 2022 - 13:00 · 3 minutes

    AVvXsEjFbllJaWz_12crtGNriYryQ7dr4uh31-CMArQRsx7hFJPXDbyJAK1p1eCZRLxYX9a1xWVLG2BRrqbBuis7AeFo0UPVhU875dusaIiEhiHj1O_v00MyHE9EIQe2RDT_xF2OBDG7XLacB8KQxClL5kkP2wtAay6DAuZ4s0ET5zJ9DvPePbm1fw=w640-h358

    Message "clipping" at Gmail is when your email message is so large that Gmail won't display the whole thing on one page. It'll show part of the message, then it'll be cut off, saying "[Message clipped]" and giving you an opportunity to click to view the whole email message in another window or tab. (You can see a screen shot of that above.)

    This can be sub-optimal for senders, because this amounts to an email message with sections both " above the fold " and "below the fold" -- meaning that first bits of the content will display in the inbox upon initial view, and the second bits of the content won't display until the user tells Gmail to display it all by way of clicking in the appropriate place.

    In my initial research on this topic, I found that everybody in the world advertises 102KB as the HTML limit before you hit the cut-off. Meaning, the common guidance says that if your HTML message source is significantly more than 102 kilobytes in size, clipping is likely to occur. Keep your HTML smaller than 102KB and then Gmail won't clip your email message. And folks are mostly right about that...read on.

    I decided to do my own testing today and found the actual limit to be around 105KB (for me, anyway), and I noted that the limit can vary based on how your email message is encoded. Does your platform encode email messages using Quoted-Printable, Base64, or just leave the source of the email unencoded? All three methods are fairly common. Quoted-Printable and Base64 are broadly used to encode fancier email messages containing content with alternate character sets that can't reliably encoded in 7-bit ASCII . This encoding helps protect messages so that when decoded, they display properly for the recipient, but that encoding will increase the amount of space needed to store an email message in transit. Point being, you'd think that this means that with, say, a Base64-encoded message, the effective Gmail clipping limit could be lower than the advertised limit. I tested all three encoding methods to see if that were true. And I was surprised to find that it was not quite true! A Base64 encoded message actually had to have HTML source of more than 110KB in size before clipping occurred, a wiggle room of around 5KB more versus a Quoted-Printable encoded or unencoded message.

    Doing the math to account for encoding differences is beyond my ability (my attempt to work it all out failed miserably), so instead, I will suggest that you don't need to worry about the intricacies of encoding and just aim for a limit of 102KB for your HTML source. That way, your content is likely below the cut-off limit for any type of common email encoding.

    Here's two other fun facts to keep in mind:

    This 102KB (or 105KB or whatever) limit is based on the HTML source, not the overall file size of the whole email message's raw source. Meaning that if you sent an email message using multi-part MIME with both a text part and HTML part, the limit would apply to the HTML part only , not a combination of the HTML part plus the text part plus the email headers. I personally confirmed this through a series of tests with differently sized text parts and HTML parts.

    And finally, there are some situations where email messages "clip" at Gmail even if the content is significantly smaller than 102KB in size. Why? Smart folks figured out that this is because of Gmail tripping over unencoded extended characters in HTML source (think accented characters, the copyright symbol, and so on).



    Značky: #Network, #gmail, #google, #clipping