This article is based on source-code research. The package is at v0.1 and is still in early development (as of May 2026).
What is Laravel Chisel?
Laravel Chisel is a package that provides primitives for building post-install scripts to remove unwanted features from Laravel starter kits. Starter kits ship with many features preinstalled, but for some projects certain features are unnecessary. Chisel solves this by providing an interactive way to “keep only what you need” after installation.Why is this needed?
Laravel starter kits bundle many features, but not every project needs all of them. For example:- Projects that don’t need email verification
- Projects that don’t use passkey authentication
- Configurations that don’t need certain Livewire components
Defining a chisel.php script
A starter kit that uses Chisel places achisel.php file at the project root. This file defines “which features are optional.”
Script definition methods
Interactive answer collection
collectAnswers() returns an answer collector. All methods are fluent and can be called in any order. In non-interactive environments, default values are used automatically.
An external Artisan command displays prompts using Laravel Prompts and passes the answers to Chisel.
File mutations
Usefile($path) for a single file and files(...$paths) to target multiple files.
PHP AST-based editing
php($path) provides editing using PHP AST. Changes are saved automatically when the object is destroyed.
For the basics of PHP AST (Abstract Syntax Tree) and using nikic/php-parser, see this article.
Section markers
Wrap optional code with a matching pair of comments.{}).
removeSectionMarkers('passkeys')— Removes the markers, keeps the coderemoveSection('passkeys')— Removes both the markers and the code
chisel- prefix is added automatically.
npm support
The
npm() method auto-detects npm, yarn, pnpm, and bun.
Current development status
- GitHub repository: laravel/chisel
- Release: v0.1 (published May 2026)
- Development period: Released after three months of closed development
laravel/chisel repository
Source code and the latest API reference.
Laravel starter kit official docs
See the official documentation for how to use the starter kits themselves.