Requirements
Filament requires the following to run:- PHP 8.1+
- Laravel v10.0+
- Livewire v3.0+
- Tailwind v3.0+ (Using Tailwind v4?)
Installation
Require the Table Builder package using Composer:New Laravel projects
To quickly get started with Filament in a new Laravel project, run the following commands to install Livewire, Alpine.js, and Tailwind CSS:Since these commands will overwrite existing files in your application, only run this in a new Laravel project!
Existing Laravel projects
Run the following command to install the Table Builder assets:Installing Tailwind CSS
Filament uses Tailwind CSS v3 for styling. If your project uses Tailwind CSS v4, you will unfortunately need to downgrade it to v3 to use Filament. Filament v3 can’t support Tailwind CSS v4 since it introduces breaking changes. Filament v4 will support Tailwind CSS v4.Run the following command to install Tailwind CSS with the Tailwind Forms and Typography plugins:
tailwind.config.js file and add the Filament preset (includes the Filament color scheme and the required Tailwind plugins):
Configuring styles
Add Tailwind’s CSS layers to yourresources/css/app.css:
postcss.config.js file in the root of your project and register Tailwind CSS, PostCSS Nesting and Autoprefixer as plugins:
Automatically refreshing the browser
You may also want to update yourvite.config.js file to refresh the page automatically when Livewire components are updated:
Compiling assets
Compile your new CSS and Javascript assets usingnpm run dev.
Configuring your layout
Create a newresources/views/components/layouts/app.blade.php layout file for Livewire components:
Publishing configuration
You can publish the package configuration using the following command (optional):Upgrading
Upgrading from Filament v2? Please review the upgrade guide.Filament automatically upgrades to the latest non-breaking version when you run
composer update. After any updates, all Laravel caches need to be cleared, and frontend assets need to be republished. You can do this all at once using the filament:upgrade command, which should have been added to your composer.json file when you ran filament:install the first time:
filament:upgrade does not actually handle the update process, as Composer does that already. If you’re upgrading manually without a post-autoload-dump hook, you can run the command yourself: