league/commonmark
PHP Markdown parser that fully supports the CommonMark and GitHub-Flavored Markdown specifications.
commonmark.thephpleague.comrepositorydocsplugins
league/commonmark is a PHP library that parses Markdown text to HTML. Its default converter follows the CommonMark specification, and a second converter class adds the GitHub-Flavored Markdown features: autolinks, disallowed raw HTML, strikethrough, tables and task lists. A PHP application calls the converter from its own code once Composer has installed the package.
The documentation covers configuration and customization. Colin O’Dell created the library and, according to the README, is its primary maintainer.
Worth knowing
Raw HTML and unsafe links pass through by default. The README advises setting the html_input and allow_unsafe_links options for untrusted input, and filtering raw HTML further when it is allowed. Only UTF-8 and ASCII input is supported, so other encodings need converting first.
Identity
- Status
- Active
- Maintainer
- Colin O'Dell4
- Maintained by
- Individual1
- First release
- 20146
Rendering and deploy
- Install with
- composer3
Releases
Adoption
Sources
- 2026-11-04: links, Maintained by
commonmark.thephpleague.com/ - 2026-11-04: links, Written in, License, GitHub stars
api.github.com/repos/thephpleague/commonmark - 2026-11-04: links, Categories, Runtime, Install with
github.com/thephpleague/commonmark/blob/2.10/README.md - 2026-11-04: Maintainer
github.com/thephpleague/commonmark/blob/2.10.7/LICENSE - 2026-11-04: Minimum runtime
github.com/thephpleague/commonmark/blob/2.10.7/composer.json - 2026-11-04: First release, Current major version, Last release
api.github.com/repos/thephpleague/commonmark/releases - 2026-11-04: Contributors
api.github.com/repos/thephpleague/commonmark/contributors?per_page=1 - 2026-11-04: Packagist downloads
packagist.org/packages/league/commonmark.json - 2026-11-04: Dependent packages, Dependent repositories
packages.ecosyste.ms/api/v1/registries/packagist.org/packages/league%2Fcommonmark