{"schemaVersion":"1.0","record":{"label":"MJML","description":"Open-source semantic markup and compiler for responsive HTML email templates.","aliases":["Mailjet Markup Language"],"kind":"software","website":"https://mjml.io/","overview":"MJML is a markup language and open-source compiler for responsive HTML email. Authors describe layouts with email-oriented components, then compile them into HTML. The project offers Node.js and command-line workflows, making it a candidate for applications that want reusable email templates without writing every underlying table layout by hand.","license":"MIT","lifecycle":"active","example":false,"features":[{"name":"Email HTML compilation","status":"supported","detail":"Semantic markup compiles through Node.js or CLI; compilation is separate from sending.","useCase":"Authoring and compiling responsive HTML email templates","platforms":["Node.js","Command line","JavaScript","Web"],"region":"Version, build and integration requirements apply","evidence":[{"url":"https://github.com/mjmlio/mjml/blob/master/README.md","locator":"Semantic components, Node.js, browser compiler and CLI","retrievedAt":"2026-10-07T23:34:24Z","kind":"vendor"}]},{"name":"Validation gate","status":"limited","detail":"Default soft mode can render invalid markup; strict mode rejects validation errors.","useCase":"Authoring and compiling responsive HTML email templates","platforms":["Node.js","Command line","JavaScript","Web"],"region":"Version, build and integration requirements apply","evidence":[{"url":"https://documentation.mjml.io/","locator":"Validation, ending tags, navbar and Outlook background limitations","retrievedAt":"2026-10-07T23:35:12Z","kind":"vendor"}]},{"name":"Reusable file includes","status":"limited","detail":"Current includes are opt-in and restricted to configured roots.","useCase":"Authoring and compiling responsive HTML email templates","platforms":["Node.js","Command line","JavaScript","Web"],"region":"Version, build and integration requirements apply","evidence":[{"url":"https://github.com/mjmlio/mjml/blob/master/packages/mjml-cli/README.md","locator":"Validation exit status, watch, template CSS and include allowlists","retrievedAt":"2026-10-07T23:34:31Z","kind":"vendor"}]},{"name":"Uniform interactive client behavior","status":"limited","detail":"Navbar hamburger support and Outlook backgrounds have documented client-specific restrictions.","useCase":"Authoring and compiling responsive HTML email templates","platforms":["Node.js","Command line","JavaScript","Web"],"region":"Version, build and integration requirements apply","evidence":[{"url":"https://documentation.mjml.io/","locator":"Validation, ending tags, navbar and Outlook background limitations","retrievedAt":"2026-10-07T23:35:12Z","kind":"vendor"}]}],"alternatives":[],"slug":"mjml","draftAlternatives":[{"targetSlug":"react-email","status":"limited","detail":"Can replace React-based template rendering when a dedicated markup language is preferred; templates and custom components require rewriting.","useCase":"Authoring and compiling responsive HTML email templates","platforms":["Node.js","Command line","JavaScript","Web"],"region":"Version, build and integration requirements apply","evidence":[{"url":"https://github.com/mjmlio/mjml/blob/master/README.md","locator":"Semantic components, Node.js, browser compiler and CLI","retrievedAt":"2026-10-07T23:34:24Z","kind":"vendor"},{"url":"https://react.email/docs/getting-started/migrating-to-react-email","locator":"MJML and React template conversion","retrievedAt":"2026-10-07T23:34:24Z","kind":"vendor"}]}],"evidence":[{"url":"https://github.com/mjmlio/mjml/blob/master/README.md","locator":"Semantic components, Node.js, browser compiler and CLI","retrievedAt":"2026-10-07T23:34:24Z","kind":"vendor"},{"url":"https://documentation.mjml.io/","locator":"Validation, ending tags, navbar and Outlook background limitations","retrievedAt":"2026-10-07T23:35:12Z","kind":"vendor"},{"url":"https://github.com/mjmlio/mjml/blob/master/packages/mjml-cli/README.md","locator":"Validation exit status, watch, template CSS and include allowlists","retrievedAt":"2026-10-07T23:34:31Z","kind":"vendor"},{"url":"https://github.com/mjmlio/mjml/blob/master/packages/mjml/package.json","locator":"Version 5.4.1 and compiler dependencies","retrievedAt":"2026-10-07T23:34:31Z","kind":"vendor"},{"url":"https://github.com/mjmlio/mjml/blob/master/LICENSE.md","locator":"MIT grant, notice conditions and disclaimer","retrievedAt":"2026-10-07T23:34:24Z","kind":"vendor"},{"url":"https://react.email/docs/getting-started/migrating-to-react-email","locator":"MJML and React template conversion","retrievedAt":"2026-10-07T23:34:24Z","kind":"vendor"}],"document":{"version":1,"references":[{"url":"https://github.com/mjmlio/mjml/blob/master/README.md","locator":"Semantic components, Node.js, browser compiler and CLI","retrievedAt":"2026-10-07T23:34:24Z","id":"readme","title":"MJML repository overview","kind":"vendor"},{"url":"https://documentation.mjml.io/","locator":"Validation, ending tags, navbar and Outlook background limitations","retrievedAt":"2026-10-07T23:35:12Z","id":"docs","title":"MJML documentation","kind":"vendor"},{"url":"https://github.com/mjmlio/mjml/blob/master/packages/mjml-cli/README.md","locator":"Validation exit status, watch, template CSS and include allowlists","retrievedAt":"2026-10-07T23:34:31Z","id":"cli","title":"MJML CLI documentation","kind":"vendor"},{"url":"https://github.com/mjmlio/mjml/blob/master/packages/mjml/package.json","locator":"Version 5.4.1 and compiler dependencies","retrievedAt":"2026-10-07T23:34:31Z","id":"package","title":"MJML package manifest","kind":"vendor"},{"url":"https://github.com/mjmlio/mjml/blob/master/LICENSE.md","locator":"MIT grant, notice conditions and disclaimer","retrievedAt":"2026-10-07T23:34:24Z","id":"license","title":"MJML MIT license","kind":"vendor"},{"url":"https://react.email/docs/getting-started/migrating-to-react-email","locator":"MJML and React template conversion","retrievedAt":"2026-10-07T23:34:24Z","id":"react","title":"React Email migration guide","kind":"vendor"}],"overviewCitations":["readme"],"licenseCitations":["license"],"sections":[{"id":"authoring","heading":"A compiler-based workflow","paragraphs":[{"id":"authoring-detail","content":[{"text":"MJML source describes email components rather than the complete generated HTML. The Node.js interface returns compilation output, and the CLI can write HTML to a file. A browser compiler is also documented. These routes let template generation live in a development or application workflow without requiring use of the online editor. The inspected repository package manifest identifies version 5.4.1; older snippets should be checked against the installed compiler rather than assumed to describe current options."}],"citations":["readme","package"]}]},{"id":"iteration","heading":"Iteration and build checks","paragraphs":[{"id":"iteration-detail","content":[{"text":"The command-line tool supports watching files and recompiling on changes. Its separate validation command reports errors and returns a nonzero exit status when validation fails, making it useful as a build gate. Template variables embedded in CSS may need the documented sanitization options or a decision to skip CSS minification. Those options protect template syntax during processing; they should not be read as a general guarantee that arbitrary supplied HTML is safe."}],"citations":["cli"]}]},{"id":"validation","heading":"Validation and raw content","paragraphs":[{"id":"validation-detail","content":[{"text":"The main documentation describes soft validation as the default: errors are reported but HTML is still rendered. Strict mode rejects invalid input, while skip bypasses validation. Ending tags such as mj-text can contain unprocessed HTML rather than nested MJML components. Their text is not automatically escaped, so an application must handle content insertion deliberately instead of treating successful compilation as sanitization."}],"citations":["docs"]}]},{"id":"includes","heading":"Shared files and include scope","paragraphs":[{"id":"includes-detail","content":[{"text":"Current documentation makes includes opt-in. When enabled, permitted paths are constrained to configured roots, with additional directories declared through includePath. This allows shared headers and footers without treating the entire filesystem as template input. Keep include behavior explicit in generated build configuration, particularly when moving a template from a local project to a hosted rendering service. The documented defaults are version-sensitive and are not evidence that an older installed compiler uses the same safeguards."}],"citations":["cli"]}]},{"id":"compatibility","heading":"Mail-client differences","paragraphs":[{"id":"compatibility-detail","content":[{"text":"Responsive output does not imply identical behavior everywhere. The documented navbar hamburger behavior is limited to Apple Mail clients; other clients receive inline links. Outlook desktop also has restrictions around background sizing and nested wrapper/section backgrounds. These examples make target-client testing important even when markup passes validation. No email rendering tests were performed for this submission."}],"citations":["docs"]}]},{"id":"license","heading":"Licensing and application scope","paragraphs":[{"id":"license-detail","content":[{"text":"MJML uses MIT terms, allowing modification and redistribution with notice preservation. It is an email-template compiler, not by itself a replacement for the application or service that delivers mail. The source can be compiled through the documented local interfaces; that software grant does not determine the terms of a hosted editor, rendering API or sending service."}],"citations":["license","readme"]}]},{"id":"comparison","heading":"Substitution considerations","paragraphs":[{"id":"comparison-detail","content":[{"text":"MJML is a candidate alternative to "},{"text":"React Email","targetSlug":"react-email"},{"text":" when a team prefers dedicated email markup over JSX-based authoring. The reverse migration guide explicitly requires conversion of templates and custom components, underscoring that the two source formats are not interchangeable. Choosing MJML changes the authoring and compilation layer; it does not establish automatic visual equivalence or replace the surrounding delivery workflow."}],"citations":["react","readme"]}]}]},"id":"Q345","revision":331,"updatedAt":"2026-10-11T20:10:39Z","sourceUrl":"https://substitutefor.net/entities/Q345?revision=331"}}