Starting a web application in Rust usually forces an immediate architectural tax before you write a single line of business logic. You pick an HTTP router such as Axum or Actix Web, then manually assemble separate crates for session storage, authentication guards, input validation, database migrations, background job queues, mail delivery, and WebSocket broadcasting—writing glue code and maintaining version alignment across a dozen independent dependencies.
On December 1, 2026, Laravel released the first beta of Laravel Rust (crate version 0.1.0, MIT-licensed), bringing a unified, full-stack Rust web framework built directly on Axum and Tokio. Your entire application compiles into a single self-contained binary—with database migrations embedded inside the executable—so deployment ships one artifact without requiring a runtime interpreter or source tree on the target host.
What Shipped in the December 1 Beta
Rather than attempting a mechanical line-by-line translation from another language, Laravel Rust is designed around idiomatic Rust primitives while keeping familiar directory conventions and developer ergonomics. Everything in the request and worker path runs asynchronously on Tokio, while blocking work such as password hashing and local disk I/O is automatically offloaded to Tokio's blocking thread pool so worker tasks do not stall the async executor.
The initial beta includes an integrated stack out of the box:
- HTTP & Routing: Typed routes in
src/routes/web.rsandsrc/routes/api.rs, middleware pipelines, route model binding, and compile-time route URL generation macros. - Compile-Time Validation & Security: Typed request input structs (
#[laravel::input]) with declarative validation rules, authorization gates, and typed secret wrappers (Password,PasswordHash) that prevent accidental plain-text logging or serialization. - Typed ORM, Query Builder & Migrations: Models and explicit relationships (without silent lazy-loading N+1 surprises), parameterized
db::query!SQL macros, schema builders, and embedded migrations supporting PostgreSQL, MySQL, and SQLite. - Async Concurrency & Queues: Structured concurrency helpers (
try_join!,select!,spawn_blocking,background, and process ticks) paired with background queues backed by database, Redis, SQS, or Laravel Cloud managed queues—supporting retries, job middleware, chains, and batches. - Durable Workflows: Multi-day, multi-step asynchronous workflows that checkpoint state after each step and suspend between steps or external events without holding an active worker slot.
- Frontend, Real-Time & Observability: Inertia integration for React, Vue, and Svelte alongside server-side Jinja-style views, a Rust Reverb WebSocket server for event broadcasting, mail and notifications, OpenTelemetry tracing, and isolated testing utilities.
Every scaffolded project also ships with agent instructions and skills (AGENTS.md,CLAUDE.md) tailored to the framework's conventions, pairing strict compiler feedback with deterministic project structure.
Installing and Bootstrapping a Project
To build and run Laravel Rust locally, you need Rust 1.99 or later, Node.js, and Git, along with the updated Laravel CLI:
# Install Rust toolchain (or run `rustup update` if already installed)
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
# Install the Laravel CLI on macOS or Linux
curl -fsSL https://laravel.com/install.sh | sh
laravel --version
laravel new example-app --rust
cd example-app
laravel migrate
laravel dev
On Windows PowerShell, install the CLI using:
powershell -ExecutionPolicy Bypass -c "irm https://laravel.com/install.ps1 | iex"
Running laravel new example-app --rust downloads the starter template, creates .env, installs frontend dependencies (configured with Inertia, React, TypeScript, Tailwind, and Vite), and runs the initial Cargo compilation. Because that first run compiles the Rust dependency graph from scratch, expect the initial bootstrap to take noticeably longer than subsequent incremental builds.
Once generated, laravel dev starts the HTTP server, queue worker, and Vite asset server together in a single terminal session, serving the starter application at http://127.0.0.1:8000.
Resolving CLI PATH Collisions
If laravel --version outputs an older installer version instead of starting with Laravel CLI, an existing global installer or Laravel Herd binary is shadowing ~/.laravel/bin on your PATH:
- Inspect all resolved binaries with
which -a laravel(macOS/Linux) orGet-Command laravel -All(Windows PowerShell). - Ensure
~/.laravel/binappears ahead of older global binary directories in your shell profile (~/.zshrc,~/.bashrc, or PowerShell profile). - By default, new projects configure PostgreSQL (
database-postgres) targeting a locallaraveldatabase; to use SQLite or MySQL instead, switch the database feature flag onlaravel-rustinCargo.tomltodatabase-sqliteordatabase-mysqland update.env.
Anatomy of a Laravel Rust Application
If you have worked with convention-driven MVC frameworks, the layout is immediately navigable, while every boundary leans on Rust's type system to catch mismatches at compile time rather than in production logs.
example-app/
├── Cargo.toml # Crate dependencies & database feature flags
├── .env # Runtime environment configuration
├── database/
│ └── migrations/ # Schema migrations compiled into the release binary
├── resources/
│ └── js/ # Inertia + React + TypeScript + Tailwind frontend
└── src/
├── main.rs # Application entrypoint & Tokio runtime boot
├── http/
│ ├── handlers/ # Async request handlers
│ └── middleware/ # Request/response middleware layers
├── models/ # Typed models, columns & explicit relationships
├── jobs/ # Queueable background jobs & durable workflows
└── routes/
├── web.rs # Browser routes & Inertia responses
└── api.rs # JSON/stateless API routes
Routes in src/routes/web.rs bind URI parameters directly to typed models or async closures:
use laravel::prelude::*;
use crate::http::handlers::posts;
use crate::models::User;
pub fn routes(route: &mut Router) {
route.get("/greeting", async || "Hello World");
route.get("/users/{user}", async |user: User| user.name);
route.get("/posts", posts::index);
route.get("/posts/{post}", posts::show);
route.post("/posts", posts::store);
}
When a handler declares user: User or post: Post in its signature, the framework resolves the record from the URI parameter before your handler body runs, returning a 404 response automatically if no matching record exists. Embedding migrations directly into the compiled binary also simplifies release rollouts, though large tables still require non-blocking DDL discipline—see Splitting a 400GB Production Table Without Locking Writes for safe schema evolution patterns.
Compile-Time Inputs, Queries, and Durable Workflows
Three subsystems show how Laravel Rust uses the compiler to eliminate entire classes of runtime bugs and shift failure detection left into CI builds.
1. Typed Input Validation and Mass-Assignment Safety
Instead of parsing untrusted request maps dynamically at runtime, form payloads are declared as structs annotated with #[laravel::input]. Validation rules and fill targets are verified at compile time:
use laravel::model::create;
use laravel::prelude::*;
use crate::models::{Post, User};
#[laravel::input(fills = Post)]
#[validate(authenticated)]
pub struct StorePost {
#[validate(required, max_length = 255, unique(Post::title))]
pub title: String,
#[validate(required)]
pub body: String,
}
pub async fn store(
Authenticated(user): Authenticated<User>,
Valid(input): Valid<StorePost>,
) -> laravel::Result<Redirect> {
let post = create!(Post { user: &user, ..input }).await?;
Ok(redirect!(show, &post))
}
If StorePost references a field that does not exist on Post or mismatches its column type, compilation fails before tests or servers ever start.
2. Type-Checked Queries Without Silent Lazy Loading
Database filters reference generated column constants on the model (Post::votes, Post::published_at) combined with typed operators (&, |, !). Comparing a numeric column against a string literal will not compile, and relationships must be loaded explicitly so hidden N+1 query storms cannot slip into production endpoints unnoticed:
let featured_posts = Post::query()
.filter(Post::votes.gt(100) & Post::published_at.is_not_null())
.order_by(Post::published_at.desc())
.get()
.await?;
For complex joins or custom aggregations, the db::query! macro compiles interpolated Rust expressions into parameterized SQL bindings rather than string concatenation.
3. Checkpointed Durable Workflows
Standard background queues handle short-lived tasks well, but multi-step business flows—such as onboarding sequences, payment settlement retries, or approval pipelines spanning several days—usually require external workflow engines or brittle state machines in database tables. Laravel Rust includes durable workflows directly on top of its queue workers:
use std::time::Duration;
use laravel::prelude::*;
pub async fn onboard_workspace(ctx: &mut WorkflowContext, workspace_id: i64) -> laravel::Result<()> {
ctx.step("provision-storage", async || {
provision_bucket(workspace_id).await
}).await?;
// Persists workflow checkpoint and releases the worker slot while sleeping
ctx.sleep(Duration::from_secs(86_400)).await?;
ctx.step("send-checkin-email", async || {
send_onboarding_checkin(workspace_id).await
}).await?;
Ok(())
}
Each ctx.step records its completed result so retries after a deploy or worker restart resume from the last incomplete step instead of repeating side effects, while ctx.sleep suspends execution without tying up memory or worker concurrency. When rotating signing keys or credentials used inside these workflows or services, pair them with Zero-Downtime Secret Rotation in Production Systems so in-flight checkpoints never fail mid-transition.
Build Times, Runtime Footprint, and Pre-1.0 Constraints
Adopting Laravel Rust brings distinct operational characteristics that every engineering team should weigh against its delivery constraints, especially around compilation overhead and pre-1.0 API stability:
| Operational Dimension | Observed Beta Behavior | Practical Impact on Engineering Teams |
|---|---|---|
| Cold Build Time | ~3m 1s median on cloud CI; ~19.4s local cold build on modern Apple Silicon | CI/CD pipelines need Cargo dependency caching (target/ or sccache) to avoid multi-minute deploy queues |
| Incremental Dev Rebuild | ~1.1s median for small edits on local development builds | Fast inner-loop iteration once initial dependencies are compiled |
| Runtime Memory & Concurrency | Single compiled binary on Tokio; low idle RSS (~16 MB under steady 50 RPS load) | High concurrency per container and fast cold container wake (~154 ms median scale-to-zero restore) |
| Framework Stability | Beta 0.1.0; stable target estimated ~6–8 weeks post-launch |
Pre-1.0 releases may introduce breaking API or configuration changes |
| Rust Learning Curve | Ownership, borrowing, lifetimes, and Result propagation remain visible |
Teams without Rust familiarity will spend early sprints resolving borrow-checker and trait errors |
Notice the asymmetry between local inner-loop feedback and CI/CD pipelines. A 1.1s incremental rebuild keeps local editing responsive once dependencies are warm, whereas a 3m 1s cold build on CI without a persistent Cargo cache slows down pull-request checks and rollouts fast if every pipeline runs from a clean slate. |
Second-Order Effects After Six to Twelve Months
Moving a production service onto a new 0.x Rust framework introduces three second-order realities that become obvious only after several months of real operation:
- Cargo dependency and toolchain maintenance: Rust crates evolve quickly, and pinning
0.1.xframework and ecosystem crates requires deliberate upgrade windows so security patches and bug fixes do not pile up behind large breaking diffs. - Ownership and async cancellation subtleties in complex workflows: While simple handlers feel approachable, long-lived durable workflows and concurrent task graphs (
select!, timeouts, and retries) require careful reasoning about idempotency and cancellation safety so half-finished external calls do not leave partial state. - Observability and incident debugging habits: Tracing async Tokio tasks with OpenTelemetry spans and correlating Rust compiler/runtime errors with production logs requires building team muscle memory—especially for engineers whose prior debugging toolkit centered on dynamic runtimes.
When Laravel Rust Fits and When to Wait
- Strong fit right now: Greenfield internal tools, high-concurrency APIs, webhook ingestion services, WebSocket-heavy backends, or background job/workflow services where single-binary deployment and low memory footprint pay off immediately—and where pre-1.0 upgrades are easy to absorb.
- Hold off for critical paths: Customer-facing products launching on a tight deadline or teams with zero Rust experience that cannot absorb breaking changes during the
0.xbeta window. - Deployment options: Because
cargo build --releaseemits a standalone Linux binary with embedded migrations, you can run it on any container host, VM, or on Laravel Cloud with managed PostgreSQL/MySQL, Valkey caches, managed queues, and scale-to-zero support.
Frequently Asked Questions About Laravel Rust
Is Laravel Rust ready for production?
Laravel Rust (v0.1.0 beta, released December 1, 2026) suits greenfield internal tools, high-concurrency APIs, webhook ingestion services, and background workflow workers. However, because pre-1.0 releases may introduce breaking API changes over the next six to eight weeks, teams building mission-critical customer products on tight deadlines should wait for the stable 1.0 release.
How fast is Laravel Rust in memory and build times?
In observed beta benchmarks, a compiled Laravel Rust binary runs with an idle memory footprint of roughly 16 MB RSS at 50 requests per second and wakes from scale-to-zero in ~154 ms median. Local incremental rebuilds take ~1.1 seconds once dependencies are cached, while cold builds take ~19.4 seconds on Apple Silicon and ~3 minutes on cloud CI without Cargo caching.
Does Laravel Rust replace PHP Laravel?
No. Laravel Rust is a separate, standalone full-stack framework built natively on Axum and Tokio for teams that want Rust's compile-time type safety and single-binary deployment alongside Laravel's familiar directory structure and developer ergonomics.
Which databases does Laravel Rust support?
The initial beta supports PostgreSQL (database-postgres), MySQL (database-mysql), and SQLite (database-sqlite) out of the box, with schema migrations compiled directly into the final release binary.
Pre-Adoption Checklist for Engineering Teams
- Verify toolchain prerequisites: Confirm CI runners and developer machines have Rust
1.99+, Node.js, and Git installed with Cargo build caching enabled. - Budget for pre-1.0 churn: Pin exact crate versions in
Cargo.tomland schedule time to track breaking changes until1.0stabilizes. - Audit third-party crate needs: Check whether any specialized SDKs your service depends on have mature async Tokio-compatible Rust crates.
- Establish Rust error and ownership conventions: Agree on shared error types, database transaction boundaries, and async task cancellation patterns before scaling across multiple contributors.