Update Strapi version

With this guide you will know how to upgrade your application to the latest version of Strapi.

NOTE

When a new version of Strapi is available, you will be notified both in your terminal, and in the admin panel.
Also note that you can check the Settings > Application section of the admin panel to have more information on:

  • The versions of Strapi and Node you are currently using.
  • If relevant, the versions we recommend you to upgrade to.

CAUTION

Before you start, make sure your server is not running until the end of the guide!

Upgrade your dependencies

Start by upgrading all your Strapi packages in your package.json.
For example upgrading from 3.2.4 to 3.2.5:

  1. {
  2. //...
  3. "dependencies": {
  4. "strapi": "3.2.4",
  5. "strapi-admin": "3.2.4",
  6. "strapi-connector-bookshelf": "3.2.4",
  7. "strapi-plugin-content-manager": "3.2.4",
  8. "strapi-plugin-content-type-builder": "3.2.4",
  9. "strapi-plugin-email": "3.2.4",
  10. "strapi-plugin-graphql": "3.2.4",
  11. "strapi-plugin-upload": "3.2.4",
  12. "strapi-plugin-users-permissions": "3.2.4",
  13. "strapi-utils": "3.2.4"
  14. //...
  15. }
  16. }
  1. {
  2. //...
  3. "dependencies": {
  4. "strapi": "3.2.5",
  5. "strapi-admin": "3.2.5",
  6. "strapi-connector-bookshelf": "3.2.5",
  7. "strapi-plugin-content-manager": "3.2.5",
  8. "strapi-plugin-content-type-builder": "3.2.5",
  9. "strapi-plugin-email": "3.2.5",
  10. "strapi-plugin-graphql": "3.2.5",
  11. "strapi-plugin-upload": "3.2.5",
  12. "strapi-plugin-users-permissions": "3.2.5",
  13. "strapi-utils": "3.2.5"
  14. //...
  15. }
  16. }

After editing the file run either yarn install or npm install to install the specified version.

TIP

If the operation doesn’t work, you should probably remove your yarn.lock or package-lock.json. If it still does not work, try again after also removing the folder node_modules.

Rebuild your administration panel

New releases can introduce changes to the administration panel that require a rebuild. Rebuild the admin panel with one of the following commands:

  1. yarn build --clean
  2. # or
  3. npm run build -- --clean

Extensions

If you are using extensions to create custom code or modify existing code, you will need to update your code and compare your version to the new changes on the repository. Not updating your extensions can break your app in unexpected ways we cannot predict.

Migration guides

Sometimes Strapi introduces breaking changes that need more than just the previous steps. That is the reason for the Migration guides page. Just make sure when you update your version that a migration guide exists or not.

Start your application

If you have followed the information above, you can start your application with:

  1. yarn develop
  2. # or
  3. npm run develop

🎉 Congrats, your application has been migrated!