docs/14-upgrade-guide.md
import Aside from "@components/Aside.astro"
<Aside variant="info"> If you see anything missing from this guide, please don’t hesitate to [make a pull request](https://github.com/filamentphp/filament/edit/5.x/docs/14-upgrade-guide.md) to our repository! Any help is appreciated! </Aside>The first step to upgrade your Filament app is to run the automated upgrade script. This script will automatically upgrade your application to the latest version of Filament and make changes to your code, which handles breaking changes:
composer require filament/upgrade:"^5.0" -W --dev
vendor/bin/filament-v5
# Run the commands output by the upgrade script, they are unique to your app
composer require filament/filament:"^5.0" -W --no-update
composer update
```bash
composer require filament/upgrade:"~5.0" -W --dev
vendor/bin/filament-v5
# Run the commands output by the upgrade script, they are unique to your app
composer require filament/filament:"~5.0" -W --no-update
composer update
```
Make sure to carefully follow the instructions, and review the changes made by the script. You may need to make some manual changes to your code afterwards, but the script should handle most of the repetitive work for you.
You can now composer remove filament/upgrade --dev as you don't need it anymore.
Filament v5 requires Livewire v4.0+. You can upgrade your Livewire code by following the Livewire upgrade guide.