Email preview shows raw code when theme is selected without opening the builder
Author: andersonjeccelCreated Jun 26, 2026Updated Sep 26, 2026
LabelsT2buguser-interfaceemailstalebuilder-grapesjs
Mautic Series
7.x series
Mautic installed version
7.2.0-rc
Way of installing
DDEV
PHP version
8.5
What browsers are you seeing the problem on?
Google Chrome
What happened?
When creating an email, picking a theme, and saving without ever opening the builder, the email preview shows raw HTML code instead of the rendered design. The preview only renders correctly after opening the builder at least once, even if no changes are made inside it.
How can we reproduce this issue?
- Create a segment email.
- Pick a theme from the theme selector, but do not open the builder.
- Save the email.
- Open the email preview.
The expected behavior is that the preview renders the selected theme visually. Instead, it shows the raw template code.
A workaround is to open the builder after selecting the theme (without making any changes), close it, then save. After that, the preview renders correctly.
Relevant log output
No log output. The issue is visible in the email preview in the UI.
Code of Conduct
- I confirm that I have read and agree to follow this project's Code of Conduct
Source: mautic/mautic