# mailparser

> Parse e-mails

Latest version **3.9.26** (published 2026-09-12) · MIT license · 0 weekly downloads

## Install

```sh
npm install mailparser
pnpm add mailparser
yarn add mailparser
bun add mailparser
```

## Health

**Score 68/100 (B)** — status: active.

Positive: has types package; no vulnerabilities; has provenance; recently updated; high maintenance score; high quality score.

Warnings: low downloads; no esm support.

## Facts

| | |
|---|---|
| Version | 3.9.26 |
| Published | 2026-09-12 |
| First published | 2011-09-14 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | separate (@types/mailparser) |
| Module format | CommonJS |
| Node | >=20.0.0 |
| Dependencies | 10 |
| Unpacked size | 78.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Provenance | attested (GitHub Actions) |
| GitHub stars | 1670 |
| Author | Andris Reinman |
| Maintainers | andris |

## Links

- npm: https://www.npmjs.com/package/mailparser
- Repository: https://github.com/nodemailer/mailparser
- Homepage: https://github.com/nodemailer/mailparser#readme
- Issues: https://github.com/nodemailer/mailparser/issues
- npm.io page: https://npm.io/package/mailparser

## Dependencies (10)

- [he](https://npm.io/package/he.md) 1.2.0
- [tlds](https://npm.io/package/tlds.md) 1.261.0
- [libmime](https://npm.io/package/libmime.md) 5.4.3
- [iconv-lite](https://npm.io/package/iconv-lite.md) 0.7.3
- [linkify-it](https://npm.io/package/linkify-it.md) 5.0.2
- [nodemailer](https://npm.io/package/nodemailer.md) 10.0.9
- [punycode.js](https://npm.io/package/punycode.js.md) 2.3.1
- [html-to-text](https://npm.io/package/html-to-text.md) 10.0.1
- [encoding-japanese](https://npm.io/package/encoding-japanese.md) 2.3.0
- [@zone-eu/mailsplit](https://npm.io/package/@zone-eu/mailsplit.md) 5.4.16

## Recent versions

- 3.9.26 (latest) — 2026-09-12
- 3.9.25 — 2026-09-11
- 3.9.24 — 2026-09-10
- 3.9.23 — 2026-09-07
- 3.9.22 — 2026-09-06
- 3.9.21 — 2026-09-06
- 3.9.20 — 2026-09-01
- 3.9.19 — 2026-08-31
- 3.9.18 — 2026-08-31
- 3.9.17 — 2026-08-27
- 3.9.16 — 2026-08-24
- 3.9.15 — 2026-08-07
- 3.9.14 — 2026-07-05
- 3.9.13 — 2026-07-05
- 3.9.12 — 2026-06-25
- … 128 more at https://npm.io/package/mailparser/versions

## README

# mailparser

![Nodemailer](https://raw.githubusercontent.com/nodemailer/nodemailer/master/assets/nm_logo_200x136.png)

> [!IMPORTANT]
> This module is in maintenance mode. It will continue to receive security updates and critical bug fixes, but no new features or feature changes will be added. For new projects, please consider using [PostalMime](https://github.com/postalsys/postal-mime), which works in both Node.js and browser environments.

Advanced email parser for Node.js. Everything is handled as a stream which should make it able to parse even very large messages (100MB+) with relatively low overhead.

## Installation

First install the module from npm:

```
$ npm install mailparser
```

next import the `mailparser` object into your script:

```js
const mailparser = require('mailparser');
```

## Usage

See [mailparser homepage](https://nodemailer.com/extras/mailparser/) for documentation and terms.

### License

Licensed under MIT

---
_Source: https://npm.io/package/mailparser · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
