Responsive HTML Email Templates: How to Build Them (and When Not To)

  • Nick Donaldson

    Nick Donaldson

    Senior Director of Growth, Knak

Updated Aug 4, 2026

Published Aug 29, 2024

Building responsive HTML email templates for high engagement

Dive deeper with AI

Have you ever seen those oversized checks given to lottery winners? They make for a great photo op, sure, but can you imagine trying to deposit that check at an ATM? You’d struggle to insert the massive check into the tiny slot – it’d be a hugely disappointing experience, especially if that was the only way you could redeem your winnings.

Unfortunately, for many brands, this is the experience they provide their customers through poorly designed, unresponsive emails. More than 75% of email opens now happen on mobile, and mobile-first interactions are on track to exceed 80% in 2026. Designing for mobile isn’t an option; mobile-first must be the default for modern brands. Yet, we often see brands that eschew mobile-design or even use image-only emails to connect with customers.

The solution to this challenge is to address the root cause: are your HTML email templates responsive?

Email templates are used by brands in their marketing automation systems, such as Marketo or Pardot, to help marketers stay on-brand and provide users with consistent experiences. The template provides the structure, and marketing teams can then adjust various elements to customize the email. Templates dictate high level design decisions such as typography and layout without hindering creative freedom.

Unlike web development, which enjoys a uniform approach from browsers on handling modern features of HTML and CSS, email development has inconsistent support across clients. This can make creating responsive HTML email templates challenging, but it’s not insurmountable.

In this post, we're going to look at how to develop responsive HTML email templates using a modern approach. First, let's look at the decision to build emails from scratch or to use a no-code email template builder.

No-Code HTML Email Template Builders vs Hand-Coding Email Templates

To design responsive marketing emails without code, use a no-code email builder: it writes the fluid, media-query-driven HTML for you, so every email you build is responsive by default.

Before you start your HTML email template building journey, it’s important to know you have a choice. You can use no-code HTML email template builders or you can hand-code emails. Whether you're a developer or a marketer, the no-code option is almost always the preferred solution. Here's our case:

  • By utilizing drag-and-drop functionality and pre-built templates, no-code builders are faster and more efficient than hand-coding.
  • No-code platforms offer robust customization features such as using custom fonts and advanced interactivity.
  • Tools like Knak create email templates that are compatible across email clients by default and provide testing tools to ensure emails render perfectly, even for the most obscure clients.
  • The learning curve for no-code tools is quite easy, and building emails can be fun for anyone, even marketers with no knowledge of HTML or CSS.
  • Create perfectly responsive emails that are designed for and compatible with any mobile device

No-code email platforms like Knak have teams of developers whose job it is to ensure the platform stays up to date with the latest accessibility and compliance best practices. As you build the email template with a drag-and-drop interface, the tool compiles the HTML and CSS behind the scenes to make your email. The output of no-code and hand-coding is effectively the same – if anything, no-code tools have stronger quality checks.

In short, we recommend using a no-code email template builder. (Get a demo of Knak if you're not convinced)

That said, if a no-code tool isn't an option or you're just interested in what goes into making a responsive HTML email template, then the rest of this blog will be well worth your time.

You'd be in plenty of company: 28% of teams still use custom HTML coded by developers to build their emails.

Understanding Responsive HTML Email Templates

What is a responsive HTML email template? Responsive email templates are coded to automatically adjust layout and content based on screen size and device type. Responsive design uses fluid grids and images that can be dynamically resized to optimize your customer’s experience across desktop and mobile devices.

Think of HTML email templates like library bookshelves. They are solid structures which you can use to stack, organize, and display books to potential borrowers. The actual books themselves can be easily swapped without altering the foundational structure or organization. Regardless of whether you are displaying cookbooks or science fiction novels, the size and shape of the shelves remain consistent.

The same holds true for HTML email templates. The structure you create in your template will be used to display content for different types of email content. You may have a webinar email template that works great for invitations – in a pinch, you could reuse the template for a customer event invitation while providing a consistent user experience across devices and screen sizes. The images, copy, and headlines you use in the email are easily swappable because the HTML email template handles the details of making the email responsive. Once the template handles layout, you can go further and personalize what each recipient sees with dynamic content.

Key Characteristics of Responsive Email Templates

If you are coding email templates from scratch, then you'll need to consider three key characteristics of responsive email templates:

  1. Fluid Layouts
  2. Media Queries
  3. Mobile-First Design

Fluid Layouts

Fluid layouts refer to using percentage-based widths rather than fixed pixels for HTML elements. This is important because it allows elements like images, text blocks, and containers to scale relative to screen size. If you were to use fixed pixels for an image and set an image container to 600 pixels, the email client will follow that direction regardless of screen size. This can obviously lead to poor user experience on smaller devices.

By using percentage-based widths, you give the email client instructions to display elements according to the screen size. For instance, if you wanted your email banner to occupy the full page, you may set the banner image to a width of 100%.

While fluid layouts are integral to responsive design in your HTML templates, it can be more complex to code from scratch. You'll need to ensure you manage your widths and consider the overall design layout to ensure elements don't become disproportionate or warped. Not only that, but as is too common in email development, not all email clients support required CSS properties like ‘max-width’ to enable these features, requiring workarounds.

Media Queries

Media queries are a CSS technique used to apply different styles based on characteristics of a user's devices, such as screen width or resolution. This technique is a mainstay of responsive design across web and email development because of its ability to dynamically respond to the user's context.

Email designers define custom "breakpoints" which trigger the media query rules to be applied. Web design juggles breakpoints for tablets, laptops, and desktops, but email is simpler: emails render in a fixed container, and you typically need just one breakpoint.

  • Desktop: emails render in a fixed-width container, typically 600 to 640px wide.
  • Mobile: a single breakpoint around 480 to 600px switches the layout to a fluid, single-column view for screens 320 to 480px wide.

Applying media queries is a key component of responsive email template design, and once applied they should be rigorously tested to ensure they work correctly. It’s also worth mentioning that media queries aren’t universally supported. Apple Mail, Gmail, and the new Outlook handle them well, but classic Outlook for Windows still renders email with the Word engine and ignores them. Microsoft is migrating users to the new Outlook in stages, and classic Outlook remains supported into 2029, so plan for both.

Mobile-First Design

Mobile-first design is exactly as it sounds: designing for mobile devices and then progressively enhancing the layout for larger screens. With three out of four email opens happening on mobile, this is a call to action for every marketer to adopt a mobile-first approach to email template development. Categorized inboxes raise the stakes further: Apple Mail on modern iPhones files marketing email into its own tab, so a cramped, unresponsive first screen is often the only impression you get.

The benefit of mobile-first is that you spend time developing the most important features of your email first, resulting in a cleaner, more focused design. It simplifies your design process by putting the most challenging work at the beginning of your workflow. Mobile-first isn’t without its challenges, as developers have to work within the constraints of smaller screen sizes.

From a design perspective, this often means focusing design on simpler layout structures like using a single-column layout. It makes sense as it utilizes the common paradigm of vertical scrolling to view more content. For content development, mobile-first necessitates prioritizing which content is placed earlier in the content often resulting in more focused copy and better calls-to-action.

Mobile-first isn't without its challenges, as developers have to work within the constraints of smaller screens sizes. And while it seems logical that you can enhance smaller designs to larger screens, this isn't always as easy as it seems. Lastly, we'd be remiss not to mention the compatibility issues that plague email development – what works in one client doesn't always translate to other clients.

Three approaches to responsive email design

When it comes to designing responsive HTML email templates, it's important to note that there are different approaches to email design. Each has its own strength and weaknesses; you have to decide which approach works best for your audience.

Email Type

Responsive Emails

Characteristics

Fluid layouts using percentage-based widths, media queries for custom breakpoints, dynamic scaling across devices, optimal display on any screen size (mobile, tablet, desktop).

Advantages

Seamless experience across devices, increased engagement due to optimized design for each screen, future-proof for new devices.

Challenges

Complex to design and code, compatibility issues with some email clients that don't support media queries (e.g., older versions of Gmail).

Email Type

Mobile-Friendly Emails

Characteristics

Fixed-width layouts (typically 320-480px), simplified design with larger touch-friendly buttons, optimized primarily for smartphones, static layout.

Advantages

Simple and fast to design and develop, good for quick implementation and short-term campaigns, guaranteed usability on mobile.

Challenges

Limited adaptability to larger screens (e.g., tablets, desktops), less engaging visual experience on non-mobile devices.

Email Type

Hybrid Emails

Characteristics

Combination of flexible layouts (percentage-based) and fixed-width elements, avoids heavy reliance on media queries, adaptive design that adjusts to a variety of screen sizes.

Advantages

Broader compatibility across email clients, including those with limited media query support (e.g., Outlook), balanced complexity.

Challenges

Limited customization and dynamic scaling compared to fully responsive designs, harder to implement for complex layouts.

Responsive templates for transactional email (statements, receipts, notifications)

A responsive account statement email uses a single-column, table-based layout that keeps line items readable at 320px wide without pinching or horizontal scrolling. The same pattern covers receipts, invoices, and order notifications: transactional emails where the recipient needs to read data, not admire a design. A few things separate transactional templates from marketing templates:

  • Data density: balances, line items, and totals belong in real HTML tables with fixed labels and fluid value columns, so numbers stay aligned on any screen.
  • Maximum client coverage: statements go to every customer on every email client, not just the marketable segment. Hybrid coding (fluid tables with fixed-width fallbacks) renders correctly even where media queries fail.
  • Text-first and retrievable: people come back for these emails. In one study, 56% of users searched their inbox for a receipt in the past week. Real text, descriptive alt text, and semantic tables make statements findable and screen-reader friendly.
  • Dark mode legibility: forced color inversion hurts most where numbers meet backgrounds, so test statements in dark mode before sending.
  • A separate sending stream: transactional email should go out on its own stream and sender reputation, apart from marketing sends.

The hybrid approach in the table above is the standard pattern for transactional templates. Knak itself is built for marketing and internal email creation rather than transactional sending, but the template principles are identical.

Basic HTML and CSS Structure for Email Templates

Email templates are written using HTML and CSS, which are interpreted and rendered by email clients to display content to recipients. The underlying structure of the HTML file and usage of elements are integral to setting up a strong foundation for responsive template design.

Think of HTML as setting up the overall structure and scaffolding for your email template. It provides a basic framework, but the design and appearance are controlled by CSS. Together, the HTML and CSS allow you to design emails and make those emails responsive. Email design, as we've seen, isn't as straightforward as modern web development. Modern HTML and CSS standards aren't always uniformly accepted by all email clients.

For example, modern CSS in web development makes use of flexbox and grid techniques to enable responsive, fluid layouts for web pages. In email, unfortunately, we're still using the HTML table element for layouts. This can be frustrating for developers coming from web development into the world of email design, but it’s the reality. Challenges like this make a compelling argument for no-code email builders like Knak.

There is also a new reader to design for. Gmail entered its Gemini era in January 2026, putting AI summaries in front of roughly 3 billion users, which means the first contact with your message is increasingly a machine-written summary. Clean, semantic HTML structure is no longer just a rendering concern; it is machine readability. We cover this shift in depth in designing email for machines.

Here are some common considerations and best practices for structuring HTML and CSS in your email templates.

HTML/CSS Consideration

DOCTYPE Declaration

Best Practices

Use <!DOCTYPE html> to ensure the email renders in standards mode across all email clients.

HTML/CSS Consideration

HTML Tag Usage

Best Practices

Wrap the entire email content within <html> and </html> tags to define the structure.

HTML/CSS Consideration

Viewport Meta Tag

Best Practices

Set the viewport for mobile devices using <meta name="viewport" content="width=device-width, initial-scale=1">.

HTML/CSS Consideration

Using Tables for Layout

Best Practices

Use percentage-based widths for tables (e.g., width="100%") and avoid deep nesting for proper rendering.

HTML/CSS Consideration

Defining Inline Styles

Best Practices

Apply inline CSS for maximum compatibility across email clients that strip out external styles.

HTML/CSS Consideration

Alt Text for Images

Best Practices

Always include descriptive alt text for images to improve accessibility and provide context when images are blocked.

HTML/CSS Consideration

Responsive Image Widths

Best Practices

Set image widths using width="100%" and max-width properties to ensure proper scaling across devices.

HTML/CSS Consideration

Spacing with Padding

Best Practices

Use padding within <td> tags instead of margin for consistent spacing across email clients.

HTML/CSS Consideration

Avoiding Divs and Floats

Best Practices

Avoid using divs and floats as many email clients, especially older ones, may strip or ignore these elements.

HTML/CSS Consideration

Conditional Comments for Outlook

Best Practices

Use conditional comments to apply styles specifically for Outlook clients (e.g., <!--[if mso]>).

HTML/CSS Consideration

Semantic Table Roles

Best Practices

Add role="presentation" to layout tables so screen readers and machine parsers skip them, and reserve real data tables (with header cells) for content like line items.

Responsive HTML email template code (copy and paste)

The considerations above come together in a surprisingly small amount of code. Here is a minimal hybrid responsive email template you can copy and adapt. It uses a wrapper table that fills small screens and caps at 600px on desktop, plus a conditional comment so classic Outlook for Windows gets a fixed-width table it can understand.

<!DOCTYPE html>

<html lang="en" xmlns:o="urn:schemas-microsoft-com:office:office">

<head>

<meta charset="utf-8">

<meta name="viewport" content="width=device-width, initial-scale=1">

<title>Your subject line</title>

</head>

<body style="margin:0; padding:0; background-color:#f4f4f4;">

<center style="width:100%;">

<!--[if mso]>

<table role="presentation" width="600" cellpadding="0" cellspacing="0" border="0"><tr><td>

<![endif]-->

<table role="presentation" class="container" width="100%" cellpadding="0" cellspacing="0" border="0" style="max-width:600px; margin:0 auto; background-color:#ffffff;">

<tr>

<td style="padding:24px; font-family:Arial, Helvetica, sans-serif; font-size:16px; line-height:1.5; color:#222222;">

<h1 style="margin:0 0 16px; font-size:24px; line-height:1.3;">Your headline</h1>

<p style="margin:0 0 16px;">Your body copy goes here. Keep it in real HTML text, not an image.</p>

<p style="margin:0;"><a href="https://example.com" style="color:#0a66c2;">Your call to action</a></p>

</td>

</tr>

</table>

<!--[if mso]>

</td></tr></table>

<![endif]-->

</center>

</body>

</html>

The fluid-table basics do the heavy lifting: width="100%" with max-width:600px means the table shrinks with small screens and stops growing at desktop size, even in clients that ignore media queries entirely.

To go from fluid to fully responsive, add one media query to the head of the template:

<style>

@media only screen and (max-width:600px) {

.container { width:100% !important; }

.stack { display:block !important; width:100% !important; }

.mobile-padding { padding:16px !important; }

}

</style>

Give any side-by-side table cells the class "stack" and they will collapse into stacked, full-width blocks below 600px. That single breakpoint is all most email templates need.

Finally, make the template dark-mode safe by declaring color-scheme support and setting intentional dark styles:

<meta name="color-scheme" content="light dark">

<meta name="supported-color-schemes" content="light dark">

<style>

@media (prefers-color-scheme: dark) {

.email-bg { background-color:#1a1a1a !important; }

.email-text { color:#eeeeee !important; }

}

</style>

Clients treat dark mode differently: Apple Mail respects your declared color schemes, while Gmail may force-invert colors it thinks are too bright, which is why transparent PNGs and intentional dark palettes matter. For the full technique set, see our guide to designing emails that work in dark mode.

Testing HTML Email Templates

Are your HTML email templates responsive? You must test them to ensure they work on all email clients and devices to answer that question. Email testing is a key component of the email design lifecycle and is critical for catching errors and making last-minute optimizations to your template. Testing now will save you time and pain down the line – there’s nothing worse than discovering an error from your users instead of catching it during the design process.

Here are some of the most important things to check in your testing process:

  • Are your emails cross-client compatible? Do they work with all major clients? Even Outlook?
  • How do your emails render in light and dark mode? Many users default to dark mode, and Gmail and Apple Mail invert colors differently, so check forced inversion against your intended dark styles.
  • How are email clients rendering your HTML and CSS?
  • Are your emails accessible? Do they have good contrast ratios and utilize alt text for images?
  • Is your email under Gmail’s clipping limit? Gmail truncates messages larger than about 102KB of HTML, hiding the rest of your email (including the unsubscribe link) behind a "View entire message" link.

For a deeper process, see our guides to email client compatibility testing and the most common email rendering issues and how to fix them.

The Case for No-Code Email Tools

There's nothing inherently wrong with coding emails from scratch; however, as we've seen, email development and, particularly, responsive template design are complex and nuanced processes. No-code tools like Knak take care of all the heavy lifting for you. Instead of wrestling with media queries and custom breakpoints to solve for different devices, you can focus on iterating creative designs using a drag-and-drop builder.

No-code tools are backed by teams of engineers (like our staff at Knak) whose primary job is to ensure that the HTML and CSS output by the tool is responsive by design. We obsess over cross-client compatibility and mobile responsiveness so you don’t have to. Modern marketing and development are hard enough without having to deal with archaic email clients and edge cases: leave the hard stuff to us!

Regardless of how you code your emails, one thing is clear: your email templates must be responsive. Your customers expect it – no, they deserve it. By adopting a mobile-first philosophy, you'll deliver better email experiences no matter the device your recipients use.

Frequently Asked Questions


Share this article

  • Nick Donaldson 2025 headshot gradient

    Author

    Nick Donaldson

    Senior Director of Growth, Knak

Why marketing teams love Knak

  • 95%better, faster campaigns = more success

  • 22 minutesto create an email*

  • 5x lessthan the cost of a developer

  • 50x lessthan the cost of an agency**

* On average, for enterprise customers

** Knak base price

Ready to see Knak in action?

Get a demo and discover how visionary marketers use Knak to speed up their campaign creation.

Watch a Demo
green sphere graphic used for decorative accents - Knak.com