PHPackages                             robquistnl/simplehtmltotext - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. robquistnl/simplehtmltotext

ActiveLib[Utility &amp; Helpers](/categories/utility)

robquistnl/simplehtmltotext
===========================

A Simple PHP Class to transform HTML to Text

v1.1.1(9y ago)9115.1k↓34.8%3[5 issues](https://github.com/RobQuistNL/SimpleHtmlToText/issues)MITPHPPHP &gt;=5.3.0

Since Nov 21Pushed 9y agoCompare

[ Source](https://github.com/RobQuistNL/SimpleHtmlToText)[ Packagist](https://packagist.org/packages/robquistnl/simplehtmltotext)[ Docs](https://github.com/RobQuistNL/SimpleHtmlToText)[ RSS](/packages/robquistnl-simplehtmltotext/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (1)Versions (8)Used By (0)

SimpleHtmlToText
================

[](#simplehtmltotext)

[![Build Status](https://camo.githubusercontent.com/bbbc9702b4c1deb80d0bd21171167512d73bc7b52942243d6fc4e376700c43e6/68747470733a2f2f7472617669732d63692e6f72672f526f6251756973744e4c2f53696d706c6548746d6c546f546578742e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/RobQuistNL/SimpleHtmlToText)[![Latest Stable Version](https://camo.githubusercontent.com/8d6019efe21581919691270660556a42e0b891d034f927edec390192be65b74c/68747470733a2f2f706f7365722e707567782e6f72672f726f6271756973746e6c2f73696d706c6568746d6c746f746578742f762f737461626c65)](https://packagist.org/packages/robquistnl/simplehtmltotext)[![Total Downloads](https://camo.githubusercontent.com/d62d11000f965b715de120eaad70a3e294ee059d9a92213b92244556cbf3697c/68747470733a2f2f706f7365722e707567782e6f72672f726f6271756973746e6c2f73696d706c6568746d6c746f746578742f646f776e6c6f616473)](https://packagist.org/packages/robquistnl/simplehtmltotext)[![License](https://camo.githubusercontent.com/139b6b9eca2e9adaa4852ac1efb47e66590bfa8d8569e64413ed86dc608562fa/68747470733a2f2f706f7365722e707567782e6f72672f726f6271756973746e6c2f73696d706c6568746d6c746f746578742f6c6963656e7365)](https://packagist.org/packages/robquistnl/simplehtmltotext)

A simple PHP class for transforming HTML to plain text (e.g. for emails)

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

[](#installation)

Install using composer (`composer require robquistnl/simplehtmltotext`).

Usage
-----

[](#usage)

```
$myHtml = 'This is HTMLHeaderNewlines';
echo (new Parser())->parseString($myHtml);
```

Returns:

```
**This is HTML**
### Header ###

Newlines

```

Supported tags
--------------

[](#supported-tags)

Currently only a few basic tags are supported, and no CSS is checked.

- `br`
- `hr`
- `h1`, `h2`, `h3`, `h4`, `h5`, `h6`
- `table`, `tr`, `td`, `th` (Very basic support)
- `b`, `strong`, `u`, `i`, `em`
- `a` Simple support; `Click here` becomes `Click here (http://example.org)`
- `img` Simple support; `` becomes ` ` and `` becomes `(title)`
- `ul`, `ol`, `li`, `dd`, `dt`

###  Health Score

34

—

LowBetter than 77% of packages

Maintenance9

Infrequent updates — may be unmaintained

Popularity39

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity63

Established project with proven stability

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

Total

6

Last Release

3462d ago

### Community

Maintainers

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

---

Top Contributors

[![RobQuistNL](https://avatars.githubusercontent.com/u/1442796?v=4)](https://github.com/RobQuistNL "RobQuistNL (8 commits)")

---

Tags

html2textHTMLToTextsimplehtml2text

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/robquistnl-simplehtmltotext/health.svg)

```
[![Health](https://phpackages.com/badges/robquistnl-simplehtmltotext/health.svg)](https://phpackages.com/packages/robquistnl-simplehtmltotext)
```

###  Alternatives

[magepow/flipbook

Magento 2 Flipbook

1013.8k](/packages/magepow-flipbook)

PHPackages © 2026

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