Skip to main content
HTML Elements

<div>

HTML element · 14 supported, 0 partial, 0 unsupported across 15 clients

The <div> element is a generic block-level container and is supported by every email client. However, it is far less reliable than <table> for layout purposes — Outlook on Windows applies inconsistent margin and padding to divs, and several clients reset block-level styles at div boundaries. Best practice in email development is to use tables for layout and divs only for grouping styled content within a cell.

Client Support

ClientCategoryEngineSupport
GmailwebmailGmail WebSupported
Gmail AndroidmobileGmail MobileSupported
Gmail iOSmobileGmail MobileSupported
Outlook 365webmailOutlook WebSupported
Outlook (New)desktopOutlook WebSupported
Outlook ClassicdesktopMicrosoft WordSupported
Outlook iOSmobileOutlook MobileSupported
Outlook AndroidmobileOutlook MobileSupported
Apple MaildesktopWebKitSupported
Apple Mail iOSmobileWebKitSupported
Yahoo MailwebmailYahooSupported
Samsung MailmobileSamsungSupported
ThunderbirddesktopGeckoSupported
HEY MailwebmailWebKitSupported
SuperhumandesktopBlinkUnknown

Client-by-client behaviour for <div>

Fully supports <div> (14): Gmail, Gmail Android, Gmail iOS, Outlook 365, Outlook (New), Outlook Classic, Outlook iOS, Outlook Android, Apple Mail, Apple Mail iOS, Yahoo Mail, Samsung Mail, Thunderbird, HEY Mail.

Behaviour unverified in: Superhuman.

When to use <div> in email

  • Wrapping styled text content inside a <td> for additional padding or background-color.
  • Grouping related inline elements with shared dark-mode color overrides.
  • Hosting media query targets inside an Outlook-conditional fallback wrapper.

Rendering behaviour and edge cases

  • Outlook on Windows applies margin and padding to divs inconsistently — never use a <div> for spacing critical to layout.
  • Some clients collapse adjacent divs that have background-color set when content height is zero.
  • Yahoo Mail's sanitizer occasionally rewrites class names on div elements, breaking class-based selectors.

Recommended fallback strategy

Use <table> for any structural layout and reserve <div> for inline content grouping inside cells. Always verify Outlook rendering before relying on margin or padding applied to a <div>.

Related Features

Test your email across all 15 clients

Preview rendering, catch CSS issues, and get actionable fixes — free.

Try Emailens Free

Support data last updated Apr 27, 2026 · synced from caniemail.com via @emailens/engine.