PHPackages                             sc0/parsedown - 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. [Parsing &amp; Serialization](/categories/parsing)
4. /
5. sc0/parsedown

ActiveLibrary[Parsing &amp; Serialization](/categories/parsing)

sc0/parsedown
=============

Parser for Markdown.

2.1.0(9y ago)027.1k↓100%MITPHPPHP &gt;=5.5.0

Since Jul 10Pushed 9y ago1 watchersCompare

[ Source](https://github.com/sc0rp10/parsedown)[ Packagist](https://packagist.org/packages/sc0/parsedown)[ Docs](http://parsedown.org)[ RSS](/packages/sc0-parsedown/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (3)Dependencies (1)Versions (70)Used By (0)

Parsedown
---------

[](#parsedown)

[![Build Status](https://camo.githubusercontent.com/6e2be7cad7fe1abd6aeb694b0764039582234e298bf3afc9ae0143b9d31dda7c/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f736330727031302f7061727365646f776e2e737667)](https://travis-ci.org/sc0rp10/parsedown)[![Total Downloads](https://camo.githubusercontent.com/b67f381073fa9cea5f57c7b84bece57947788c38a58518107efff0d40679650d/687474703a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f7363302f7061727365646f776e2e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/sc0/parsedown)

Better Markdown Parser in PHP

[Demo](http://parsedown.org/demo) | [Benchmarks](http://parsedown.org/speed) | [Tests](http://parsedown.org/tests/) | [Documentation](https://github.com/erusev/parsedown/wiki/)

### Features

[](#features)

- Super Fast
- [GitHub flavored](https://help.github.com/articles/github-flavored-markdown)
- Extensible
- Tested in 5.6 to 7.0 and in HHVM
- [Markdown Extra extension](https://github.com/erusev/parsedown-extra)

### Installation

[](#installation)

Install [the composer package](https://packagist.org/packages/sc0/parsedown).

### Example

[](#example)

```
use Sc\Parsedown\Parsedown;

$Parsedown = new Parsedown();

echo $Parsedown->text('Hello _Parsedown_!'); # prints: Hello Parsedown!
```

More examples in [the wiki](https://github.com/erusev/parsedown/wiki/) and in [this video tutorial](http://youtu.be/wYZBY8DEikI).

#### Advanced example with renaming tags/attributes

[](#advanced-example-with-renaming-tagsattributes)

```
use Sc\Parsedown\Parsedown;

$replacements = [
    'p' => [
        'tag_name' => 'div', // rename  to
        'class' => 'paragraph', // add class="paragraph" attribute to div
        'data-foo' => 'bar', // add data-foo="bar" attribute to div
    ],
    'em' => [
        'class' => 'em', // don't rename tag, just add class="em" attribute to em
    ],
];
$Parsedown = new Parsedown($replacements);

echo $Parsedown->text('Hello _Parsedown_!'); # prints: Hello Parsedown!
```

### Questions

[](#questions)

**How does Parsedown work?**

It tries to read Markdown like a human. First, it looks at the lines. It’s interested in how the lines start. This helps it recognise blocks. It knows, for example, that if a line start with a `-` then it perhaps belong to a list. Once it recognises the blocks, it continues to the content. As it reads, it watches out for special characters. This helps it recognise inline elements (or inlines).

We call this approach "line based". We believe that Parsedown is the first Markdown parser to use it. Since the release of Parsedown, other developers have used the same approach to develop other Markdown parsers in PHP and in other languages.

**Is it compliant with CommonMark?**

It passes most of the CommonMark tests. Most of the tests that don't pass deal with cases that are quite uncommon. Still, as CommonMark matures, compliance should improve.

**Who uses it?**

[phpDocumentor](http://www.phpdoc.org/), [October CMS](http://octobercms.com/), [Bolt CMS](http://bolt.cm/), [Kirby CMS](http://getkirby.com/), [Grav CMS](http://getgrav.org/), [Statamic CMS](http://www.statamic.com/), [Herbie CMS](http://www.getherbie.org/), [RaspberryPi.org](http://www.raspberrypi.org/) and [more](https://www.versioneye.com/php/erusev:parsedown/references).

**How can I help?**

Use it, star it, share it and if you feel generous, [donate](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=528P3NZQMP8N2).

###  Health Score

37

—

LowBetter than 82% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity24

Limited adoption so far

Community19

Small or concentrated contributor base

Maturity73

Established project with proven stability

 Bus Factor1

Top contributor holds 84% 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 ~20 days

Recently: every ~71 days

Total

69

Last Release

3301d ago

Major Versions

0.9.4 → 1.0.0-rc.12014-04-17

1.8.1 → 2.0.02017-04-24

PHP version history (2 changes)1.7.0PHP &gt;=5.3.0

2.0.0PHP &gt;=5.5.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/05412073e9ab3b583dff0ed26b1d30504692d9a514faae652f0262a88aa92075?d=identicon)[sc0rp10](/maintainers/sc0rp10)

---

Top Contributors

[![erusev](https://avatars.githubusercontent.com/u/184170?v=4)](https://github.com/erusev "erusev (431 commits)")[![sc0rp10](https://avatars.githubusercontent.com/u/597762?v=4)](https://github.com/sc0rp10 "sc0rp10 (29 commits)")[![hkdobrev](https://avatars.githubusercontent.com/u/506129?v=4)](https://github.com/hkdobrev "hkdobrev (18 commits)")[![wkpark](https://avatars.githubusercontent.com/u/232347?v=4)](https://github.com/wkpark "wkpark (6 commits)")[![rhukster](https://avatars.githubusercontent.com/u/1084697?v=4)](https://github.com/rhukster "rhukster (6 commits)")[![KaneCohen](https://avatars.githubusercontent.com/u/578455?v=4)](https://github.com/KaneCohen "KaneCohen (3 commits)")[![naNuke](https://avatars.githubusercontent.com/u/4591126?v=4)](https://github.com/naNuke "naNuke (3 commits)")[![HelpingHand1](https://avatars.githubusercontent.com/u/197991695?v=4)](https://github.com/HelpingHand1 "HelpingHand1 (2 commits)")[![cebe](https://avatars.githubusercontent.com/u/189796?v=4)](https://github.com/cebe "cebe (2 commits)")[![PhrozenByte](https://avatars.githubusercontent.com/u/920356?v=4)](https://github.com/PhrozenByte "PhrozenByte (2 commits)")[![teaqu](https://avatars.githubusercontent.com/u/583418?v=4)](https://github.com/teaqu "teaqu (1 commits)")[![kelunik](https://avatars.githubusercontent.com/u/2743004?v=4)](https://github.com/kelunik "kelunik (1 commits)")[![MechanicalMann](https://avatars.githubusercontent.com/u/2583176?v=4)](https://github.com/MechanicalMann "MechanicalMann (1 commits)")[![donatj](https://avatars.githubusercontent.com/u/133747?v=4)](https://github.com/donatj "donatj (1 commits)")[![henriquemoody](https://avatars.githubusercontent.com/u/154023?v=4)](https://github.com/henriquemoody "henriquemoody (1 commits)")[![grogy](https://avatars.githubusercontent.com/u/1322983?v=4)](https://github.com/grogy "grogy (1 commits)")[![garoevans](https://avatars.githubusercontent.com/u/1016708?v=4)](https://github.com/garoevans "garoevans (1 commits)")[![scarwu](https://avatars.githubusercontent.com/u/616443?v=4)](https://github.com/scarwu "scarwu (1 commits)")[![tbreuss](https://avatars.githubusercontent.com/u/1334161?v=4)](https://github.com/tbreuss "tbreuss (1 commits)")[![josephok](https://avatars.githubusercontent.com/u/5212375?v=4)](https://github.com/josephok "josephok (1 commits)")

---

Tags

parsermarkdown

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/sc0-parsedown/health.svg)

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

###  Alternatives

[erusev/parsedown

Parser for Markdown.

15.0k151.8M724](/packages/erusev-parsedown)[league/commonmark

Highly-extensible PHP Markdown parser which fully supports the CommonMark spec and GitHub-Flavored Markdown (GFM)

2.9k404.0M698](/packages/league-commonmark)[erusev/parsedown-extra

An extension of Parsedown that adds support for Markdown Extra.

84314.8M192](/packages/erusev-parsedown-extra)[parsedown/parsedown

Parser for Markdown.

21342.8k3](/packages/parsedown-parsedown)[tovic/parsedown-extra-plugin

Configurable Markdown to HTML converter with Parsedown Extra.

5933.7k](/packages/tovic-parsedown-extra-plugin)[taufik-nurrohman/parsedown-extra-plugin

Configurable Markdown to HTML converter with Parsedown Extra.

5932.3k](/packages/taufik-nurrohman-parsedown-extra-plugin)

PHPackages © 2026

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