Custom CSS

Appearance

Custom CSS

Style both the editor chrome and the email output with your own CSS.

Two independent layers: appearance.customCss restyles the editor UI to match your product, while a design's body.custom_css is injected into the exported email. The Theme manager in the editor needs the appearance.custom_themes entitlement; body.custom_css itself is always exported.

For token-based theming, see custom themes.

How body.custom_css is exported

  • It goes in its own <style> block after the built-in rules, so your rules win by order. CSS inlining keeps that block, so @media queries and class rules still work.
  • <style> and <script> tags and CDATA markers are stripped. An unfinished rule at the end, such as a selector still being typed, is dropped instead of breaking the rest.
  • A Google Fonts @import url(https://fonts.googleapis.com/...) line also becomes a <link> in the head (up to five), because inlining drops @import from the style block.
  • On the edit canvas the same CSS is scoped to the canvas, so it does not restyle the editor around it.
css
.mailkaro-button-link { text-transform: uppercase; }

Users write it in the Theme manager, which is shown only when the plan includes appearance.custom_themes. A design that already has custom_css still exports it.

appearance.customCss

Pass a string or a list of strings, which are joined. Unlayer's appearance.customCSS is read as the same option. Tags such as <style> are stripped, and this CSS only reaches the editor's own interface, never the email.