PHPackages                             toitzi/laravel-cloudflare-mail - 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. toitzi/laravel-cloudflare-mail

ActiveLibrary[Mail &amp; Notifications](/categories/mail)

toitzi/laravel-cloudflare-mail
==============================

Cloudflare Email Service transport for Laravel mailers.

v1.0.2(3mo ago)41.1k↑33.3%MITPHP ^8.4

Since Apr 16Compare

[ Source](https://github.com/toitzi/laravel-cloudflare-mail)[ Packagist](https://packagist.org/packages/toitzi/laravel-cloudflare-mail)[ Docs](https://github.com/toitzi/laravel-cloudflare-mail)[ RSS](/packages/toitzi-laravel-cloudflare-mail/feed)WikiDiscussions Synced 3w ago

READMEChangelog (3)Dependencies (7)Versions (5)Used By (0)

Laravel Cloudflare Mail
=======================

[](#laravel-cloudflare-mail)

`toitzi/laravel-cloudflare-mail` adds a `cloudflare` mail transport to Laravel so mailers can send through the [Cloudflare Email Service REST API](https://developers.cloudflare.com/email-service/).

Installation
------------

[](#installation)

```
composer require toitzi/laravel-cloudflare-mail
```

Laravel discovers the package automatically.

Configuration
-------------

[](#configuration)

Define the mailer directly in `config/mail.php`:

```
'default' => env('MAIL_MAILER', 'cloudflare'),

'mailers' => [
    'cloudflare' => [
        'transport' => 'cloudflare',
        'account_id' => env('CLOUDFLARE_EMAIL_ACCOUNT_ID'),
        'api_token' => env('CLOUDFLARE_EMAIL_API_TOKEN'),
        'base_url' => env('CLOUDFLARE_EMAIL_BASE_URL', 'https://api.cloudflare.com/client/v4'),
        'timeout' => 30,
        'connect_timeout' => 10,
    ],
],
```

Supported message features
--------------------------

[](#supported-message-features)

- HTML and plain text bodies
- `from`, `to`, `cc`, `bcc`, and single `reply-to` addresses
- Standard attachments
- Custom headers such as `In-Reply-To`, `References`, `List-Unsubscribe`, and `X-*`

Limitations
-----------

[](#limitations)

- Cloudflare's REST API only supports a single `from` address.
- Cloudflare's REST API only supports a single `reply_to` address.
- Inline attachments are not supported by the REST API and will throw an exception.

Testing
-------

[](#testing)

```
composer test
```

###  Health Score

44

—

FairBetter than 90% of packages

Maintenance81

Actively maintained with recent releases

Popularity25

Limited adoption so far

Community2

Small or concentrated contributor base

Maturity54

Maturing project, gaining track record

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 ~0 days

Total

3

Last Release

99d ago

PHP version history (2 changes)v1.0.0PHP ^8.3

v1.0.2PHP ^8.4

### Community

Maintainers

![](https://www.gravatar.com/avatar/d6703727b3960b7f58325c28bc4b209acd71c4499d383759fc8397db50691a17?d=identicon)[toitzi](/maintainers/toitzi)

###  Code Quality

TestsPest

### Embed Badge

![Health badge](/badges/toitzi-laravel-cloudflare-mail/health.svg)

```
[![Health](https://phpackages.com/badges/toitzi-laravel-cloudflare-mail/health.svg)](https://phpackages.com/packages/toitzi-laravel-cloudflare-mail)
```

###  Alternatives

[psalm/plugin-laravel

Psalm plugin for Laravel

3345.3M347](/packages/psalm-plugin-laravel)[illuminate/mail

The Illuminate Mail package.

5910.6M528](/packages/illuminate-mail)[illuminate/notifications

The Illuminate Notifications package.

483.1M1.2k](/packages/illuminate-notifications)[api-platform/laravel

API Platform support for Laravel

58174.6k17](/packages/api-platform-laravel)

PHPackages © 2026

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