v4 code migration: Backend overview
This backend code migration overview is part of the v4 code migration guide.
Most of the backend of Strapi has been entirely rewritten in Strapi v4:
- The core features of a Strapi v4 server (routes, policies, controllers, and services) use factory functions. The new files can be created with the interactive
- There is a clear distinction in Strapi v4 between policies and middlewares, which leads to the introduction of route middlewares.
The project structure is different in Strapi v3 and Strapi v4. The project structure can be migrated with Strapi codemods and is not covered in details in this guide.
Migrating the backend of a Strapi application to v4 requires updating all of these core features:
Optionally, depending on your usage of these features in Strapi v3, you might also need to migrate:
The dedicated short guides listed in this backend code migration guide are not exhaustive resources for the v4 backend customization features, which are described in the backend customization documentation.
Once the backend of Strapi has been migrated to v4, you can proceed to migrating the frontend.