Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Using exported MailChimp template with SMTP

I have exported a template to HTML from MailChimp. When I open it in the browser it looks correct - gray background, text formatting, etc (like the classic MailChimp templates). When I send test emails from MailChimp it opens correctly in Gmail, Outlook, etc.

When I use the same HTML code and send via SMTP from Python with SendGrid or Gmail the background disappears, the styling isn't as consistent, the text formatting disappears.

What's happening here?

like image 592
Kyle Johnson Avatar asked Mar 25 '26 05:03

Kyle Johnson


1 Answers

When exporting a HTML template from MailChimp, the styles do not get inlined automatically and therefore won't render properly in email clients like Gmail. MailChimp has a tool to inline the CSS here:

http://templates.mailchimp.com/resources/inline-css/

So the process is to export from MailChimp, paste into the inline-css tool, and then use that HTML.

like image 65
Kyle Johnson Avatar answered Mar 26 '26 20:03

Kyle Johnson



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!