parsica-php/parsica
Parsica is a PHP parser combinator library for building custom parsers from small reusable pieces. Compose complex grammars with a fluent API, parse strings into structured results, and handle errors cleanly—ideal for DSLs, config formats, and language tooling.
The easiest way to build robust parsers in PHP.
Note: Parsica is very early stage, expect things to break.
Donate via my GitHub Sponsor Page.
A lot of research & development went into this project. We think it can become the mainstream choice for building reliable parsers in PHP, and serve as a foundation for many advancements. Your support will help us to reach that goal.
E-mail us at contact@value-object.com to discuss options.
Submit questions as Github issues. Help us help you by submitting short bits of code that demonstrate the problem, and that can easily be copied and run.
How can I help you explore Laravel packages today?