News

Official Laravel Zed Extension: LSP for PHP & Blade

Published
Official Laravel Zed Extension: LSP for PHP & Blade image

The Laravel team has published an official Laravel extension for Zed that connects Laravel LSP to the editor. Version 0.1.0 landed in Zed's extension registry on July 30th, and it gives you completions, hover information, diagnostics, document links, and code actions in your PHP and Blade files.

Laravel LSP is the first-party language server that was revealed at Laracon US 2026. It knows about your application, so it can complete config keys, route names, view paths, translation strings, middleware, container bindings, Livewire components, and Inertia pages, then flag the ones that don't exist. The Zed extension is the piece that wires all of that into the editor for you.

Getting Started

Open the Extensions page from Zed's command palette with zed: extensions, search for Laravel (Official), and click Install. That's it. You don't need to install laravel/lsp yourself, since the extension downloads the language server binary and then checks for updates at most once every two hours.

No configuration is required by default. If you do want to pass initialization options to the server, you can set them under lsp.laravel.initialization_options in your Zed settings:

{
"lsp": {
"laravel": {
"initialization_options": {
"phpEnvironment": "sail"
}
}
}
}

Here phpEnvironment tells the server how to find a working PHP command for indexing your project. It defaults to auto, which tries Herd, Valet, Sail, Lando, DDEV, and then local PHP. Every individual LSP feature can be toggled through the same options object, and the full list lives in the Laravel LSP repo.

This isn't the only Laravel extension for Zed. Mike Bronner's community Laravel extension is still actively developed, and the two take different approaches. Laravel LSP runs PHP scripts in your project to ask the framework directly, which is what phpEnvironment is for, while the community server parses your files with tree-sitter and never runs your application. The community README recommends against running both at once, so pick the one that fits how you work.

Zed now joins Sublime Text, Cursor, and the Laravel VS Code extension with official support, and Neovim and OpenCode can point at the same server with a few lines of config.

Read more

The extension is MIT licensed, and you can install it from the Zed extension page or browse the source on the laravel/zed-extension GitHub repo.

Eric L. Barnes photo

Eric is the creator of Laravel News and has been covering Laravel since 2012.

Sponsored

masteringlaravel logo
Laravel Code Review

Get expert guidance in a few days with a Laravel code review

Visit Laravel Code Review

The latest

View all →
Laravel Head: Manage Meta Tags, Open Graph, and JSON-LD image

Laravel Head: Manage Meta Tags, Open Graph, and JSON-LD

Read article
PhpStorm 2026.2 Released image

PhpStorm 2026.2 Released

Read article
Laravel Doctor: Diagnose Your App With One Artisan Command image

Laravel Doctor: Diagnose Your App With One Artisan Command

Read article
CPX: The Composer Package Executor for PHP image

CPX: The Composer Package Executor for PHP

Read article
Laravel AI SDK Adds Human-in-the-Loop Tool Approval image

Laravel AI SDK Adds Human-in-the-Loop Tool Approval

Read article
Pest 5 Released With Test Impact Analysis, Agent Verification, and Evals image

Pest 5 Released With Test Impact Analysis, Agent Verification, and Evals

Read article