How to Add a Border Around an Entire Dynamics 365 Marketing Email
Question details
The user wants to know how to apply a global outer border around a marketing email that contains multiple sections.

- Product
- Dynamics 365 Marketing
- Device & OS
- not provided
- Scenario
- Designing a marketing email with multiple stacked sections and needing a unified outer border to contain the entire design.
- Observed behavior
- Seeking the correct HTML configuration, template settings, or email-designer workaround to create a global email-container border.
Ensure you have permission to edit email templates in Dynamics 365 Marketing and are comfortable accessing the HTML source code of your email draft.
Use an HTML Wrapper Table in the Email Designer
Since a native global border setting might not apply across multiple distinct design blocks, wrapping your entire email content in a custom HTML table is the most reliable workaround.
Email clients parse code differently, and adding a border directly to the body tag can yield inconsistent results. Wrapping your entire layout in a table structure ensures the border displays uniformly in Outlook, Gmail, and other clients.
Navigate to Dynamics 365 Marketing, open your email draft, and click on the HTML tab to access the source code.
Scroll through the code to find the opening <body> tag or the outermost <div> that contains all of your email sections.
Directly after the opening body tag, insert a wrapper table code: <table style='border: 1px solid #cccccc; width: 100%; max-width: 600px; margin: 0 auto;' cellspacing='0' cellpadding='0'><tr><td>
Scroll to the very bottom of your email code, just before the closing </body> tag, and close the wrapper: </td></tr></table>
Switch back to the visual designer to preview the layout, then send a test email to yourself to verify the border renders correctly.

Consult the Dynamics 365 Community for Template Support
If the visual designer overrides your custom HTML wrapper, posting in the Dynamics 365 community is the best way to get product-specific workarounds.
Draft Your Marketing Content with WPS Office
While Dynamics 365 Marketing handles your email distribution, drafting your marketing copy, planning layouts, and collaborating with your team is easier with a lightweight office suite. WPS Office is a free, highly compatible alternative to Microsoft Office.
- 1. Download WPS Office: Visit the official WPS Office website and download the free installer for your operating system.
- 2. Install the Application: Run the setup file and follow the on-screen instructions to install the lightweight suite.
- 3. Open Your Documents: Launch WPS Office to instantly open, edit, and collaborate on your Word, Excel, or PowerPoint files without formatting loss.

Frequently Asked Questions
Why doesn't Dynamics 365 Marketing have a simple 'add border' button for the whole email?
Marketing emails are built using modular stacked sections or blocks to maintain mobile responsiveness. A single outer border requires wrapping all these separate blocks in a unified container, which usually requires custom HTML rather than a simple visual toggle.
Can I use CSS styling on the body tag to add an email border?
While you can add inline CSS such as style='border: 1px solid black;' to the body tag in the HTML editor, many email clients (especially desktop Outlook) strip or ignore body styles. Using an HTML wrapper table is a much more universally supported method.
Will adding a custom outer border affect my email's mobile responsiveness?
It can if not coded correctly. If you use a fixed-width wrapper table for your border (like width: 600px), it will not scale down on mobile screens. Always use percentage-based widths along with a max-width setting to preserve responsiveness.




