Auto-Generate Laravel Artisan Commands with AI

You know make:model exists. You know there are flags that generate a migration, a controller, a factory, and a seeder all at once. You just cannot remember the exact combination without opening a browser tab.

This is one of those small frictions that adds up. You stop mid-flow, Google “laravel make model with migration and controller,” scan the docs, paste the command, and get back to work. Two minutes gone. Flow broken. Multiply that by ten commands a day and it is a real cost.

In 2026, that friction is unnecessary. Here is every Artisan command worth knowing, what the flags actually do, and how AI can now generate the right command sequence for you automatically based on what you are building.

Why Artisan flags are so easy to forget

The problem is not intelligence. The problem is surface area.

Laravel’s Artisan CLI has over 100 built-in commands, and many of them have flags that interact with each other in ways that are not obvious until you have used them enough times to memorize them. A junior or mid-level developer who switches between projects, frameworks, and contexts does not always have that repetition.

make:model Post generates a model. make:model Post -m generates a model and a migration. make:model Post -mc generates a model, migration, and controller. make:model Post -mcrf generates a model, migration, controller, resource, and factory. make:model Post --all generates all of the above plus a seeder and a policy.

None of that is hard to understand once you see it. It is just hard to hold in memory when you are focused on the feature you are building, not the commands that scaffold it.

Artisan commands developers Google most often

These are the commands with flag combinations that cause the most tab-switching.

make:model

The most used Artisan command and the one with the most useful flag combinations.

Model only
php artisan make:model Post

Model + migration
php artisan make:model Post -m

Model + migration + controller
php artisan make:model Post -mc

Model + migration + resource controller
php artisan make:model Post -mcr

Model + migration + API controller (no create/edit methods)
php artisan make:model Post –migration –controller –api

Model + migration + controller + factory + seeder
php artisan make:model Post -mcfs

Everything at once
php artisan make:model Post –all

The --all flag is the one most developers do not know about until someone tells them. It generates the model, migration, factory, seeder, policy, resource controller, and resource class in one command.

make:controller

Basic controller
php artisan make:controller PostController

Resource controller (index, create, store, show, edit, update, destroy)
php artisan make:controller PostController –resource

API resource controller (no create or edit — no form views needed)
php artisan make:controller PostController –api

Invokable controller (single-action, uses __invoke)
php artisan make:controller PostController –invokable

Resource controller bound to a model (type-hints the model automatically)
php artisan make:controller PostController –resource –model=Post

The --invokable flag is the one people reach for on single-action routes and then forget the exact flag name. The --model flag on a resource controller is even more overlooked and saves meaningful boilerplate.

make:migration

Create a new table
php artisan make:migration create_posts_table

Add a column to an existing table
php artisan make:migration add_published_at_to_posts_table

Modify an existing table
php artisan make:migration modify_posts_table

Specify the table explicitly
php artisan make:migration create_posts_table –create=posts

Modify with explicit table
php artisan make:migration add_status_to_posts –table=posts

Laravel infers intent from the migration name when you follow the naming convention, which is why create_posts_table generates a migration with a create schema call and add_column_to_table generates one with an alter call.

make:request

Form request for validation
php artisan make:request StorePostRequest
php artisan make:request UpdatePostRequest

No flags here, but developers often forget that the convention is StoreModelRequest and UpdateModelRequest to keep naming predictable across a team.

make:policy

Policy without a model
php artisan make:policy PostPolicy

Policy with model methods pre-generated (viewAny, view, create, update, delete, restore, forceDelete)
php artisan make:policy PostPolicy –model=Post

The --model flag generates all the policy methods with the correct model type-hint already in place. Without it, you get an empty class. Most developers want the pre-generated methods and forget to add the flag.

make:resource

API resource (single model)
php artisan make:resource PostResource

Resource collection
php artisan make:resource PostCollection –collection

make:job

Synchronous job
php artisan make:job ProcessPost

Job forced to be synchronous (does not implement ShouldQueue)
php artisan make:job ProcessPost –sync

make:event and make:listener

php artisan make:event PostPublished
php artisan make:listener SendPublicationNotification –event=PostPublished

The --event flag wires the listener to the event automatically. Without it, you add the event type-hint manually.

make:mail

php artisan make:mail PostPublished
php artisan make:mail PostPublished –markdown=emails.post-published

The --markdown flag generates a mailable class with a markdown view already configured. Without it, you get the class and have to set up the view reference yourself.

make:notification

php artisan make:notification PostApproved
php artisan make:notification PostApproved –markdown=notifications.post-approved

make:test

Feature test (default, goes in tests/Feature)
php artisan make:test PostTest

Unit test (goes in tests/Unit)
php artisan make:test PostTest –unit

Pest test
php artisan make:test PostTest –pest

Pest unit test
php artisan make:test PostTest –pest –unit

make:middleware

php artisan make:middleware EnsurePostIsPublished

make:command

php artisan make:command PublishScheduledPosts

Ready to Code Smarter with Laravel?

Meet LaraCopilot — your AI full-stack assistant built for Laravel developers.
Skip the boilerplate, build faster, and focus on what matters: problem solving.

Try LaraCopilot Now

Flag combinations most developers always Google

For quick reference, these are the ten combinations that cause the most tab-switching.

GoalCommand
Model + migration + resource controllermake:model Post -mcr
Model + everythingmake:model Post --all
API controller with model bindingmake:controller PostController --api --model=Post
Single-action controllermake:controller PostController --invokable
Policy with all model methodsmake:policy PostPolicy --model=Post
Listener wired to an eventmake:listener SendNotification --event=PostPublished
Mailable with markdown viewmake:mail PostPublished --markdown=emails.post-published
Pest feature testmake:test PostTest --pest
Add column migrationmake:migration add_status_to_posts --table=posts
Resource collectionmake:resource PostCollection --collection

Where AI makes this better

Knowing the flags is useful. But even if you bookmark this page, you still have to translate “I want to build a Post feature with a model, migration, resource controller, policy, API resource, and Pest tests” into the right sequence of commands manually.

That translation step is where most of the friction actually lives. It is not that the commands are hard. It is that going from “here is what I am building” to “here is the exact sequence of commands that scaffolds it correctly” requires a mental context-switch that interrupts the real work.

LaraCopilot handles that translation automatically. Describe what you are building, and it generates the full connected scaffold directly, with all the right pieces wired together from the start. Not a list of commands to run one by one, but a complete, framework-correct stack pushed to your repository in one session.

For junior and mid-level developers in particular, that shift matters beyond the time saved. When a tool generates code that follows correct Laravel conventions from the first generation, the developer reads framework-correct code every day. That is how conventions become instinctive rather than something you have to look up.

Artisan commands for running, not just generating

Beyond make: commands, these are the ones developers look up most often during active development.

Run migrations
php artisan migrate

Roll back the last migration batch
php artisan migrate:rollback

Roll back and re-run all migrations
php artisan migrate:fresh

Roll back, re-run migrations, and seed
php artisan migrate:fresh –seed

Run a specific seeder
php artisan db:seed –class=PostSeeder

Clear all caches
php artisan optimize:clear

Clear config cache only
php artisan config:clear

Clear route cache
php artisan route:clear

List all routes
php artisan route:list

List routes filtered by name
php artisan route:list –name=post

Run the development server
php artisan serve

Open a Tinker REPL session
php artisan tinker

A note on php artisan list and php artisan help

If you are ever unsure about a command, two built-in commands are worth knowing.

php artisan list shows every available command grouped by category.

php artisan help make:model shows the full documentation for a specific command, including every available flag and what it does.

These are always current for your installed Laravel version, which matters when behavior changes between major releases.

Ready to Code Smarter with Laravel?

Meet LaraCopilot — your AI full-stack assistant built for Laravel developers.
Skip the boilerplate, build faster, and focus on what matters: problem solving.

Try LaraCopilot Now

Stop Googling, start building

The commands are not the hard part of Laravel development. The features are. Every minute spent looking up flag combinations is a minute not spent on the work that actually requires your thinking.

Bookmark this page for the reference. And when you are ready to stop scaffolding by hand entirely and generate the full connected stack from a single description of what you are building, LaraCopilot is built exactly for that.

Try LaraCopilot Free

Top 14 Laravel Packages for Every PHP Project (2026)

Top Laravel packages are what make Laravel one of the most powerful and flexible PHP frameworks today. Laravel has become the go-to choice for building clean, scalable, and high-performance web applications. What truly sets it apart is its vibrant ecosystem of community-built packages from authentication and caching to image processing and payment integration. Choosing the right Laravel packages can save weeks of development time and make your project production-ready faster.

In this guide, we’ve handpicked the top 14 Laravel packages for every PHP project in 2026, tools trusted by developers to boost performance, streamline workflows, and simplify complex tasks. Whether you’re building a SaaS, an API, or a content platform, these packages will help you code smarter, not harder.

These tools are hand-picked for their consistent popularity, broad adoption, and vital functionality making any Laravel project faster, more secure, and easier to maintain.

Here are the top 14 Laravel packages for every PHP project in 2025, with in-depth details about each one and best practices for their use.

1. Laravel Debugbar

Laravel Debugbar is a comprehensive debugging tool that overlays a toolbar on your application. It provides real-time insights into database queries, route matching, variables, and more. This package is tremendously helpful during development and performance optimization. It highlights slow queries, points out N+1 query issues, and allows drilling into request details.

  • Best Use: Integrate from the start of development for actionable feedback, but disable in production environments.
  • Key Features: Timeline, database queries, memory usage, log viewer, and mail analysis.
  • Why Essential: It accelerates troubleshooting and helps ensure robust code before deployment.

2. Spatie Laravel Permission

Spatie Laravel Permission offers an elegant and flexible way to manage user roles and permissions inside your applications. With this package, you can easily assign roles to users, check permissions, and implement fine-grained access control.

  • Best Use: Perfect for SaaS, CMS, or any system with granular user control.
  • Key Features: Role assignment, middleware integration, blade directives, database-stored permissions.
  • Why Essential: Keeps code maintainable and policies transparent, enhancing security.

3. Laravel Horizon

Laravel Horizon provides a beautiful dashboard and code-driven configuration for your application’s Redis queues. Horizon allows you to monitor key metrics, job throughput, and failures in real time. The dashboard helps maintain healthy queues and smooth background job execution.

  • Best Use: Recommended for any app using Laravel queues (e.g., email, billing, uploads).
  • Key Features: Jobs analytics, failed jobs tracking, queue management UI.
  • Why Essential: Ensures job reliability and quick debugging of background tasks.

4. Laravel Excel

Laravel Excel is the go-to solution for importing and exporting Excel, CSV, and other spreadsheet files in Laravel. It smoothly integrates with Eloquent, supports chunked data operations, and allows data handling with minimum memory usage.

  • Best Use: Reporting, analytics, and bulk data management in enterprise applications.
  • Key Features: Import/export large datasets, CSV/Excel support, batch processing, high-performing with queues.
  • Why Essential: Saves countless hours for data operations and is widely trusted for flawless performance.

5. Spatie Laravel Backup

Spatie Laravel Backup is a robust tool for automating full backups of your Laravel application. It zips your code and database for local or cloud storage, with features like password protection, notifications, and backup monitoring.

  • Best Use: Integrate into all production apps for disaster recovery and compliance.
  • Key Features: Database + file backup, health checks, backup history, notifications.
  • Why Essential: Protects against data loss, enables rapid disaster recovery, and meets backup policies.

6. Laravel DB Auditor

Laravel DB Auditor empowers developers and DBAs to review and enforce database standards, constraints, and best practices. It supports MySQL, SQLite, and PostgreSQL for auditing database schema, constraints, and compliance.

  • Key Features: CLI and Web UI for database audits, detects missing constraints, evaluates standards, CLI reports to add constraints, tracks table creation/updates.
  • Installation Command: composer require --dev vcian/laravel-db-auditor
  • Why Essential: Ensures database integrity, enforces best practices, and streamlines schema health checks, especially critical for enterprise and regulated sector projects.

7. Pulse Active Sessions

Pulse Active Sessions is a Laravel Pulse card that visualizes and tracks active user sessions, providing real-time data and activity graphs for administrators.

  • Key Features: Live tracking of logged-in users, session management insights, Pulse dashboard integration, useful for capacity planning and real-time audits.
  • Installation Command: composer require vcian/pulse-active-sessions
  • Why Essential: Increases administrative visibility into user activity and engagement, aiding in moderation, support, and platform health.

8. Laravel Telescope

Laravel Telescope acts as a powerful debugging and insights companion tailored specifically for Laravel. It captures requests, exceptions, scheduled tasks, queries, jobs, notification events, and more with searchable, filterable logs.

  • Best Use: Monitoring, advanced debugging, and profiling during development and staging.
  • Key Features: Request/exception monitoring, job tracking, event logging, in-app UI.
  • Why Essential: Offers deep insights into your app’s inner workings, leading to better stability and faster issue resolution.

9. Laravel Socialite

Laravel Socialite streamlines OAuth authentication for major providers (Google, Facebook, GitHub, etc.), helping you add social login with minimal fuss. It’s officially maintained and supports custom providers.

  • Best Use: Applications demanding frictionless sign-up and login.
  • Key Features: Out-of-the-box social login, extensible for new providers, secure delegate authentication.
  • Why Essential: Reduces user churn, offloads credential management, and improves UX for onboarding.

10. Livewire

Laravel Livewire enables developers to build rich, reactive interfaces using simple PHP and Blade, replacing much of the JavaScript usually required. It empowers developers to build interactive user interfaces like file uploads, wizards, and modal dialogs with server-side logic.

  • Best Use: Any application needing modern, dynamic UIs without deep JavaScript expertise.
  • Key Features: Interactive, real-time UI updates, minimal JS, seamless Laravel integration.
  • Why Essential: Dramatically boosts productivity for developing modern interfaces using Laravel’s ecosystem

11. Spatie Media Library

The Spatie Media Library package manages file uploads, transformations, and associations between models and files. It automatically creates different image conversions (thumbnails, previews), handles remote/cloud storage, and links files intuitively to Eloquent models.

  • Best Use: Systems with user file uploads, galleries, or content management.
  • Key Features: Automatic file conversions, responsive image support, cloud integration, comprehensive API.
  • Why Essential: Handles file uploads and associations painlessly without writing custom boilerplate code.

12. Barryvdh Laravel IDE Helper

This tool generates helper files for your IDE, vastly improving the Laravel development experience through auto-completion and code navigation. It’s invaluable for boosting productivity, especially on large teams and codebases.

  • Best Use: All Laravel projects for improved developer experience across IDEs like PhpStorm, VS Code.
  • Key Features: Generates docs and meta files, supports model autocompletion, easy integration.
  • Why Essential: Reduces errors, accelerates onboarding, and supercharges daily coding workflows.

13. Laravel IP Gateway

Laravel IP Gateway provides IP whitelisting and blacklisting support, allowing developers to control access to their Laravel application with fine-grained rules. This is crucial for increasing API security and preventing unauthorized access.

  • Key Features: Whitelist/blacklist any number of IP groups, configurable middleware, customizable redirect on denial, and support for both blacklist and whitelist logic.
  • Installation Command: composer require vcian/laravel-ip-gateway
  • Why Essential: Protects sensitive endpoints and services with flexible, centralized IP restrictions, ideal for admin panels and private APIs.

14. Pulse Docker Monitor

Pulse Docker Monitor is a Laravel Pulse card for real-time monitoring of Docker containers, providing insights into resource usage (CPU and memory) directly within your Laravel Pulse dashboard.

  • Key Features: Visualizes Docker containers’ CPU and RAM usage, integrates into the Laravel Pulse ecosystem, and supports Livewire/Pulse dashboard enhancements.
  • Installation Command: composer require vcian/pulse-docker-monitor
  • Why Essential: Empowers DevOps and developers to monitor infrastructure health from within the Laravel admin interface, leading to proactive maintenance and troubleshooting.

Ready to Code Smarter with Laravel?

Meet LaraCopilot — your AI full-stack assistant built for Laravel developers.
Skip the boilerplate, build faster, and focus on what matters: problem solving.

Try LaraCopilot Now

What are Difference Between Laravel Packages

PackageKey PurposeWhy Use ItStars
Laravel DebugbarDebuggingProfiling, DB/query insights18,774
Spatie Laravel PermissionAccess ControlRole/permission management12,691
Laravel HorizonQueue ManagementReal-time job monitoring5,079
Laravel ExcelData Import/ExportExcel/CSV handling, reporting12,572
Spatie Laravel BackupBackup/RecoveryAutomated, encrypted backups5,892
Laravel TelescopeApplication InsightsIn-depth logging, profiling5,079
Laravel SocialiteAuth IntegrationOAuth social login5,300
LivewireReactive UIModern, JS-lite interfaces23,174
Spatie Media LibraryFile ManagementUpload, transform, associate files5,900+
IDE HelperIDE IntegrationCode autocompletion14,738

Additional Honorable Mentions

Best Practices for Package Use

  • Audit Dependencies Regularly: Only use packages actively maintained and compliant with Laravel’s latest version.
  • Review Documentation: Each recommended package includes extensive docs read before integration for smooth adoption
  • Performance: Benchmark after addition, especially for debugging or monitoring packages, to avoid performance pitfalls
  • Environment Switches: Ensure that development packages (Debugbar, Telescope) are disabled in production to secure and optimize live applications.

Ready to Code Smarter with Laravel?

Meet LaraCopilot — your AI full-stack assistant built for Laravel developers.
Skip the boilerplate, build faster, and focus on what matters: problem solving.

Try LaraCopilot Now

Wrap-up!

The right Laravel packages can transform any PHP project improving speed, code quality, and long-term scalability. Whether you’re building a SaaS, an eCommerce platform, or internal business tools, these community-driven packages help you ship faster, debug smarter, and keep your applications stable for years.

As you plan your next Laravel build, focus on packages with strong adoption, active maintenance, and solid documentation. Choosing well-supported tools today ensures smoother development, easier updates, and future-ready apps that grow with your business.

And if you want to supercharge your workflow with AI-powered code assistance, try LaraCopilot today, your new coding partner built for modern Laravel development.