#1616th of 43 in Code review and testing
larastan
PHPStan extension that finds type errors and bugs in Laravel code
- Stars
- 6.6k
- License
- MIT
- Last commit
- Nov 2026
- Last release
- Nov 2026
- Language
- PHP
6,329 on 21 Apr 20266,553 on 10 Nov 2026
From GitHub's daily star counts.
Checked on GitHub.
Overview
Larastan is a PHPStan extension for Laravel, installed as a Composer dev dependency. It boots the application container so it can resolve types that only exist at runtime, such as Eloquent magic, and reports errors at PHPStan levels up to 10. It is not an AI tool; it is rule-based code analysis that runs locally or in CI.
Who it is for: Laravel developers who want static analysis locally and in CI
Strengths
- Resolves much of Laravel's magic by booting the app container to compute types
- Baseline files let legacy codebases adopt a higher PHPStan level gradually
- Composer install plus a phpstan.neon file; no service to run
- Adds Laravel-specific rules, custom PHPDoc types and config parameters
Weaknesses
- Not AI-based; a rule-based static analyser that fits this list loosely
- Version 3.x needs PHP 8.2+ and Laravel 11.15+
- Boots the application during analysis, and large projects may hit memory limits
- Some Laravel magic still needs entries in an ignore-errors list
What it needs
- no GPU
- Needs PHP 8.2+, Laravel 11.15+, Composer, PHPStan
What changed
From the release notes. No flag means the note does not say so, not that the upgrade is safe.
Also in Code review and testing
See all 43| Rank | Project | Score |
|---|---|---|
| 1 | playwrightCross-browser automation and end-to-end test framework for Chromium, Firefox and WebKit | 94 out of 100 |
| 2 | nxMonorepo build system with task caching, affected-only runs and CI integration | 93 out of 100 |
| 3 | open-code-reviewGo CLI that reviews Git diffs with an LLM agent and line-level comments | 92 out of 100 |
| #4 | bendDependent-typed language where AI-written code must prove rules in LAWS.bend | 88 out of 100 |
| #5 | maestroYAML-based UI and end-to-end test framework for Android, iOS and web | 88 out of 100 |