A micro-framework for crafting beautiful command-line applications — powered by the Laravel components you already know, with nothing you don't need.
composer create-project laravel-zero/laravel-zero my-cli
$ php my-cli deploy production
Resolving strategy ................................. DONE
Building assets ..................................... DONE
Running migrations .................................. DONE
Warming caches ...................................... DONE
SUCCESS Deployed to production in 2.41s.
$ ▌
Trusted by teams shipping developer tools
Batteries, not baggage
Laravel Zero strips the HTTP kernel, routing, sessions and views out of the equation, and keeps the parts that make Laravel a joy — the container, the console kernel, and the ecosystem.
Compile your whole application into one standalone PHAR with a single command. Ship it anywhere PHP runs.
Signatures, arguments, options and prompts — the exact Artisan API, with zero extra concepts to learn.
A full cron-style scheduler built in. Define schedules right next to the command they belong to.
Termwind brings a Tailwind-like syntax to the terminal. Tables, spinners, tasks and progress bars included.
Pest is wired up from the first commit. Assert exit codes, expected output and prompted answers.
Ship updates directly to your users. The self-update add-on pulls new releases straight from GitHub.
From class to binary
A Laravel Zero command is a plain PHP class. When you're ready to distribute it, one command compiles the application — dependencies and all — into a single executable file.
app/Commands.builds/.<?php namespace App\Commands; use LaravelZero\Framework\Commands\Command; final class DeployCommand extends Command { protected $signature = 'deploy {env=staging}'; protected $description = 'Deploy the application'; public function handle(Releaser $releaser): void { $env = $this->argument('env'); $this->task('Building assets', $releaser->build(...)); $this->task('Running migrations', $releaser->migrate(...)); $this->info("Deployed to {$env}."); } }
Opt in, never out
php my-cli app:install <addon>
database
Eloquent ORM, migrations and seeders.
log
Monolog channels wired to your app.
filesystem
Local and cloud disks via Flysystem.
dotenv
Environment files for local config.
menu
Interactive, arrow-key driven menus.
http
The Laravel HTTP client, ready to go.
queue
Background jobs with your favourite driver.
self-update
Let users upgrade in place.
Free, open source and MIT licensed. Requires PHP 8.2 or higher.