Laravel Rust is here
What shipped in the Laravel Rust beta, how it works alongside Laravel PHP, and how to try it locally.
Is PHP now finally dead?!
Well, some PHP haters would love to see that happen.
Laravel Rust is here 🚀
The beta comes with routing, auth, models and queues. Inertia is there too, with React, Vue and Svelte support. Launch announcement
Taylor Otwell sees teams picking Rust for new projects. With AI agents writing more of the code, he wants Laravel to be an option for those teams too.
So, fellow PHP devs, what now?
Laravel PHP stays in active development. Weekly releases and new features continue. Taylor says the team will develop both frameworks in parallel. Let's see how long. Taylor's letter
Async by default
Laravel Rust runs on Axum and Tokio. It's async by default. While one request waits for the database, Tokio can run another on the same thread. Laravel Rust announcement
And that 18× figure? Laravel tested two read-only endpoints on Cloud. Rust hit 1,774 requests per second and PHP hit 97 on Octane and FrankenPHP. Those were each app's best ten seconds without HTTP errors. Benchmark report
Typed models
Post::query() looks familiar, right? I'm pulling posts with at least 1,000 views. views is an integer, so try passing a string to ge() and the compiler will complain. Model docs
let popular_posts = Post::query()
.filter(Post::views.ge(1_000_i64))
.get()
.await?;
That .await? at the end is worth a look. .await waits for the query without blocking the thread. ? gives you the posts on success. If the query fails, it returns the error from the current function. Rust error handling
Durable workflows
Send a team invite. Wait two days. If it's still open, send a reminder.
use laravel::time::ToSpan;
run.step("send invitation", self.send_invitation()).await?;
run.sleep(2.days()).await?;
run.step("remind if open", self.remind_if_open()).await?;
The worker can take other jobs while the workflow sleeps. When it resumes, Laravel already has the result of the invitation step. It skips straight to checking whether a reminder is due. Workflow docs
Getting started
Want to try it? You'll need the new Laravel CLI, Rust 1.99 or later, Node.js and Git. Installation guide
laravel new example-app --rust
cd example-app
Set up your database and run laravel migrate. Then run laravel dev to start the app, a queue worker and Vite Plus.
New projects include an AGENTS.md for coding agents. The crate ships with the docs for the version you installed. Laravel News