PHPackages                             jacerider/mail\_theme - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Mail &amp; Notifications](/categories/mail)
4. /
5. jacerider/mail\_theme

ActiveDrupal-module[Mail &amp; Notifications](/categories/mail)

jacerider/mail\_theme
=====================

Provides email wrapping HTML and styling.

1.0.8(1mo ago)01.3kGPL-2.0-or-laterPHP

Since Aug 8Pushed 1mo ago1 watchersCompare

[ Source](https://github.com/jacerider/mail_theme)[ Packagist](https://packagist.org/packages/jacerider/mail_theme)[ RSS](/packages/jacerider-mail-theme/feed)WikiDiscussions develop Synced today

READMEChangelogDependencies (2)Versions (10)Used By (0)

CONTENTS OF THIS FILE
---------------------

[](#contents-of-this-file)

- Introduction
- Requirements
- Installation
- How it works
- Color variables
- Sending as HTML

INTRODUCTION
------------

[](#introduction)

Provides email wrapping HTML and styling.

REQUIREMENTS
------------

[](#requirements)

This module requires the Mailsystem module.

INSTALLATION
------------

[](#installation)

Install as you would normally install a contributed Drupal module. Visit  for further information.

HOW IT WORKS
------------

[](#how-it-works)

Every outgoing email is wrapped in an HTML template through hook\_mail\_alter().

If your theme has a logo-email.png file at its root, that image is used in the email header.

COLOR VARIABLES
---------------

[](#color-variables)

The message body may reference the wrapper's color variables with a {{ variable }} placeholder, for example:

Link

This works in any email body, including the account email templates at /admin/config/people/accounts. Available placeholders:

{{ body\_bg }} {{ content\_bg }} {{ content\_color }} {{ header\_bg }} {{ header\_color }} {{ primary\_bg }} {{ primary\_color }} {{ secondary\_bg }} {{ secondary\_color }}

Only these color variables are substituted, and the body is never evaluated as a Twig template - it is a plain allow-list substitution, safe to expose in the admin UI. Unknown placeholders are left untouched.

SENDING AS HTML
---------------

[](#sending-as-html)

Mail Theme produces HTML, but the configured mail *formatter* runs after hook\_mail\_alter() and can convert the body back to plain text. Two setups are supported:

1. Keep your existing formatter and make sure it preserves HTML. With the SMTP module, enable "Send emails as HTML" (the smtp\_allowhtml setting) on its configuration page.
2. Use the bundled "Mail Theme (HTML formatter)" plugin. On the Mail System (mailsystem) settings page, set it as the Formatter and leave your sender (PHP mailer, SMTP Mailer, ...) unchanged. This formatter never strips the HTML, so no per-sender option is required.

###  Health Score

44

—

FairBetter than 90% of packages

Maintenance91

Actively maintained with recent releases

Popularity20

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity46

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~81 days

Recently: every ~61 days

Total

9

Last Release

43d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/097ea6514c7dff8bd82162fe88411080a14444a73f86c15ab22eefe28a33059d?d=identicon)[jacerider](/maintainers/jacerider)

---

Top Contributors

[![jacerider](https://avatars.githubusercontent.com/u/638651?v=4)](https://github.com/jacerider "jacerider (14 commits)")

### Embed Badge

![Health badge](/badges/jacerider-mail-theme/health.svg)

```
[![Health](https://phpackages.com/badges/jacerider-mail-theme/health.svg)](https://phpackages.com/packages/jacerider-mail-theme)
```

###  Alternatives

[drupal/core-recommended

Locked core dependencies; require this project INSTEAD OF drupal/core.

6942.5M421](/packages/drupal-core-recommended)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
