Project structure
βοΈ Note
If the Strapi project was created with the starter CLI, its structure includes both a frontend
and backend
folder, where the backend
folder has the default structure.
Structure of a project created with the starter CLI
my-project
ββββ frontend # starter folder
ββββ backend # template folder, has the default structure of a project
ββββ node_modules
The default structure of a Strapi project created without the starter CLI depends on whether the project was created with vanilla JavaScript or with TypeScript, and looks like the following:
- JavaScript-based projects
- TypeScript-based projects
The following diagram is interactive: you can click on any file or folder name highlighted in purple to go to the corresponding documentation page.
. # root of the application
βββββ .strapi # auto-generated folder β do not update manually
β βββββ client # files used by bundlers to render the application
β β index.html
β β app.js
βββββ .tmp
βββββ build # build of the admin panel
βββββ config # API configurations
β β api.js
β β admin.js
β β cron-tasks.js
β β database.js
β β middlewares.js
β β plugins.js
β β server.js
βββββ database
β βββββ migrations
βββββ node_modules # npm packages used by the project
βββββ public # files accessible to the outside world
β βββββ uploads
βββββ src
β βββββ admin # admin customization files
β βββββ extensions # files to extend the admin panel
β β β app.js
β β β webpack.config.js
β βββββ api # business logic of the project split into subfolders per API
β β βββββ (api-name)
β β βββββ content-types
β β β βββββ (content-type-name)
β β β β lifecycles.js
β β β β schema.json
β β βββββ controllers
β β βββββ middlewares
β β βββββ policies
β β βββββ routes
β β βββββ services
β β β index.js
β βββββ components
β β βββββ (category-name)
β β β (componentA).json
β β β (componentB).json
β βββββ extensions # files to extend installed plugins
β β βββββ (plugin-to-be-extended)
β β βββββ content-types
β β β βββββ (content-type-name)
β β β β schema.json
β β β strapi-server.js
β βββββ middlewares
β β βββββ (middleware-name).js
β βββββ plugins # local plugins files
β β βββββ (plugin-name)
β β βββββ admin
β β β βββββ src
β β β β index.js
β β βββββ server
β β β βββββ content-types
β β β βββββ controllers
β β β βββββ policies
β β β package.json
β β β strapi-admin.js
β β β strapi-server.js
β ββββ policies
β β index.js # include register(), bootstrap() and destroy() functions
β .env
β package.json
The following diagram is interactive: you can click on any file or folder name highlighted in purple to go to the corresponding documentation page.
. # root of the application
βββββ .strapi # auto-generated folder β do not update manually
β βββββ client # files used by bundlers to render the application
β β index.html
β β app.js
βββββ .tmp
βββββ config # API configurations
β β api.ts
β β admin.ts
β β cron-tasks.ts
β β database.ts
β β middlewares.ts
β β plugins.ts
β β server.ts
βββββ database
β βββββ migrations
βββββ dist # build of the backend
β βββββ build # build of the admin panel
βββββ node_modules # npm packages used by the project
βββββ public # files accessible to the outside world
β βββββ uploads
βββββ src
β βββββ admin # admin customization files
β β βββββ extensions # files to extend the admin panel
β β β app.example.tsx
β β β webpack.config.ts
| | β tsconfig.json
β βββββ api # business logic of the project split into subfolders per API
β β βββββ (api-name)
β β content-types
β β β βββββ (content-type-name)
β β β β lifecycles.ts
β β β β schema.json
β β βββββ controllers
β β βββββ middlewares
β β βββββ policies
β β βββββ routes
β β βββββ services
β β β index.ts
β βββββ components
β β βββββ (category-name)
β β β (componentA).json
β β β (componentB).json
β βββββ extensions # files to extend installed plugins
β β βββββ (plugin-to-be-extended)
β β βββββ content-types
β β β βββββ (content-type-name)
β β β β schema.json
β β β strapi-server.js
β βββββ middlewares
β β βββββ (middleware-name)
β β β defaults.json
β β β index.ts
β βββββ plugins # local plugins files
β β βββββ (plugin-name)
β β βββββ admin
β β β βββββ src
β β β β index.tsx
β β β β pluginId.ts
β β βββββ server
β β β βββββ content-types
β β β βββββ controllers
β β β βββββ policies
β β β package.json
β β β strapi-admin.js
β β β strapi-server.js
β ββββ policies
β β index.ts # include register(), bootstrap() and destroy() functions
β .env
β tsconfig.json
β package.json