Designing relations in Strapi starts with which side owns the link
A team has linked articles, authors, categories and products in Strapi, and now the article list endpoint returns slowly while editors struggle to find which author or category they are changing. Both symptoms usually trace back to relation design rather than to the database alone. Relations are the wiring between content types, and their design decides the shape of your queries, what editors see on each form and how expensive a later schema change will be. Those three effects are set early, so they deserve a deliberate decision before the first content is entered.
You need to design relations on purpose once more than a few content types point at each other, once editors work across several linked entries at a time, or once front ends start requesting nested data for listing pages. The first design question is which side of each link holds the relation and whether the inverse side should be visible in the admin panel. A one-way relation keeps the model small and predictable. A bidirectional relation lets you query from both ends but adds a second place where the link is shown, populated and maintained. Decide for each pair which direction your front end actually reads from, and check that answer against your real list and detail pages.
The Strapi documentation defines the relation types, the options for each one and the behavior of the Document Service that this page builds on. Because those details can change between releases, confirm the exact relation options, populate behavior and default depths against the Strapi version you run before you finalize a model. Your own team should also confirm which relation fields appear in list views and which require a populate parameter, since that determines the query cost of each page. Treat the design as a set of decisions to record, not as settings you can assume from another project.
Which relation type fits which content shape
This table compares Strapi relation types by the content shape they connect, how editors pick related entries, and how queries read them. Use it to match a content relationship to a relation type before you build, then check the bidirectional and component rows for the trade-offs that matter in your editorial workflow.
| Content shape | Relation type to consider | How editors pick items | How queries read it |
|---|---|---|---|
| One record tied to exactly one other record, such as a product and its single spec sheet | One-to-one, usually one-way | A single picker field on one side, often limited to unlinked records | Fetched from the owning side with a populate on that field; the reverse lookup needs its own query if the inverse is not modeled |
| Many child records owned by one parent, such as an article and its authors' bios or a course and its lessons | One-to-many (parent holds the list) | A multi-select picker on the parent that adds existing entries | Parent populate returns the list; child-to-parent lookups read the single back-reference if it exists |
| Many records pointing to one shared record, such as many articles in one category | Many-to-one (child holds the reference) | A single picker on each child entry | Filter children by the parent field; the parent list is read through a reverse relation if modeled |
| Records that share many counterparts, such as articles with topics or authors with books | Many-to-many, usually bidirectional when both sides browse the link | Multi-select pickers on both sides, which can get long on busy content | Each side is populated independently; deep populates on both sides multiply the response size |
| Relation to media files, such as a hero image or a gallery | Media field (single or multiple), using the upload plugin | Editors pick from the media library or upload inline | Populated like a relation, returning file metadata and formats; the media library is not a content type editors model |
| Repeatable or nested content that belongs only to one entry, such as FAQ rows or SEO fields | Component, not a relation; see the sibling page on components vs dynamic zones | Editors fill the fields inline and cannot reuse the same item elsewhere | Read as part of the parent entry, with no separate populate of a linked type |
| Content that mixes several types in one ordered area, such as a page with varied sections | Dynamic zone, not a relation; see the sibling page on dynamic zones | Editors add and order blocks from a set of allowed components | Requires populate rules for each component in the zone; covered in the page builder sibling page |
| Relations that should be shared across locales, such as a single product referenced by every language version | Relation on a localized type, checked against how the related type is localized | Editors choose the referenced entry in each locale; confirm the behavior for your localization settings | Queries return the entry for the requested locale; confirm that related records resolve as you expect |
One-way or bidirectional: when the reverse side earns its place
When an article owns its tags, the parent is the natural place to record the relationship. Editors add tags while editing the article, the article's API response carries its tags, and nobody expects a tag to know which articles use it. A one-way relation from article to tag keeps the schema small and the write path simple, because the only record that changes is the one the editor is working on.
- Editing screen: the relation field appears only on the article, so the editor sees and controls the full list in one place.
- Query path: reading an article and its tags is a single populate from the parent, with no inverse traversal.
- Populate depth: tags rarely need their own relations, so the populate tree stays shallow.
- Consistency cost: imports write one side only, so there is no mirror record to fall out of step.
- Reverse lookups: finding all articles for a tag requires a filtered query on articles, which is acceptable for low volume but should be tested at production size.
Before choosing this pattern, confirm that no editor or front-end feature needs to list the parent from the child's side.
When a product appears on many pages, editors often need to answer questions like which pages use this product before they retire or change it. A bidirectional relation makes that inbound list visible on the product itself, which turns the reverse side from a convenience into an editorial control. The cost is that both sides now describe the same fact, and Strapi must keep them aligned on every write.
- Editing screen: the product shows the pages referencing it, which supports safe deprecation.
- Query path: reverse lookups become a direct populate from the product instead of a scan of pages.
- Populate depth: each added inverse relation deepens the graph that clients can request, so limit which inverse fields are exposed to the API.
- Consistency cost: every page save updates the product's inbound list, which adds write work and more chances for conflicting edits under concurrent saves.
- Review impact: inverse fields can be large lists, so the product edit screen may need to show a count or a filtered view instead of every entry.
Test a realistic editor workflow with the real volume of referencing pages before you commit to the inverse field.
Shared reference data, such as countries, currencies, product categories or legal disclaimers, is referenced from many content types and rarely changes. Here the question is less about editors and more about stability: a reference item should be owned by one editorial team, referenced one way, and changed with care. Whether to add an inverse depends on whether anyone needs to audit usage, not on how often the item is linked.
- Ownership: keep the reference type under a single owner, and document who may edit it, since a change propagates to every page that uses it.
- Query path: one-way references from many types keep the reference type free of growing inverse lists.
- Localization: check how relations behave across locales before assuming a shared item is shared in every language.
- Schema change risk: renaming or removing a reference type affects all referring types, so plan changes through a release process.
- Auditing: if usage reports are required, a query from the referring side may be enough without an inverse field.
Confirm with your editors whether reference items are edited in place or copied, because that choice decides whether a one-way relation is safe.
How deep relation graphs slow queries and populate calls
Every relation a request asks Strapi to resolve adds work. A populate on a single relation typically becomes one additional query and a join against the related table, and the response grows by whatever fields that related entry carries. The cost compounds when the related entries have their own relations, components or dynamic zones that are also populated. A request for an article with its author, the author's company, and each company's office locations is three levels of resolution, and the payload size is driven by the product of how many entries sit at each level, not by the depth alone. Nested populates multiply response size, so a list endpoint that returns twenty articles can quietly return thousands of related objects.
Editors make this worse without intending to. Each new relation on a content type that also points back into the graph extends the set of paths a query could follow, and a field added for one editorial purpose can become a populate target for a front end three hops away. Before go-live, list the populate paths each front-end view actually needs, and compare that list with the relations in the content model. Confirm the Strapi version and query options your team uses against the current documentation, because populate syntax and the Document Service behavior are the places where Strapi 5 projects most often get their query shapes wrong.
Controls work at three layers. In the query, request only the fields and relations the view renders, and avoid wildcard populates on list endpoints. In the API layer, give list routes their own read-side shape, either a custom controller that returns a flattened view or a front-end query that fetches the parent first and loads children on demand, so that a single route does not serve every consumer. In the data model, consider whether a deep relation is needed at all, or whether a denormalized summary field, maintained by lifecycle logic, serves the listing. Verify on a copy of production with realistic content volumes, not a seeded development database: measure response time and payload size for the heaviest list and detail requests, and rerun the check after each schema change that adds a relation.
How to model relations in Strapi step by step
This sequence turns a list of business entities into a tested set of Strapi relations that editors can manage and front-end routes can query at a known depth. Each step ends with a check so that mistakes surface while the schema is still cheap to change.
Write the questions each content type must answer
For every proposed content type, list the questions the front end and editors must answer about it, such as which articles belong to an author, which products a page shows, or which locales a document has. Include who writes the answer and how often it changes. Done when each content type has a short list of concrete questions and a named editor or developer owns each list. Check the list against the page designs, because any question no screen or route asks is a candidate for removal.
Pick the owning side of each relation
For each pair of types, decide which side stores the link. The owning side should be the one editors create or edit most often, because its form carries the field and its updates are the ones that matter for publishing. Record the decision in a short table with the owner, the reader and the reason. Check it by asking an editor to name, for a sample item, where they would add the link, and confirm they pick the same side as the table.
Choose the relation type for each link
Map each link to a Strapi relation type based on cardinality: one-to-one, one-to-many, many-to-one or many-to-many, and whether the relation is one-way or bidirectional. Confirm the exact options in the Strapi version you run, since relation field options have changed across releases. Check by drawing the schema on one page and verifying that each cardinality matches a real business rule you can point to, not a guess about future use.
Decide whether to add the inverse field
Add an inverse field only when a real query or editor screen needs to start from the other side, such as listing all articles for an author. Each inverse field adds a read path and a dependency that must be kept in sync, so omit it when the reverse lookup can be served by a filter on the owning side. Check by writing down the query each inverse field serves. If you cannot name one, remove the field and retest.
Define populate patterns for front-end routes
For each route, specify the exact relations and depth it needs, using explicit populate objects or fields lists rather than requesting everything. Keep the depth shallow for list views and deeper only for detail pages, and record which relations each route loads. Check by calling each route's API request with the planned populate and confirming the response contains the intended fields and nothing deeper. Then measure response size on a representative entry with realistic content volume.
Test the editor flow in the admin panel
Create, edit, publish and unpublish sample entries as an editor role would, linking related items from both sides where inverse fields exist. Confirm that the relation picker shows the right options, that required relations block publishing when empty, and that deleting a related entry behaves as expected. Check that the relation appears on the owning side and, if present, the inverse side, with draft and published versions consistent with your locale and review setup.
Verify API responses at each intended depth
Request each route at its planned populate depth, then at one level deeper, and compare the payloads. Confirm that the deeper request returns data only when asked, that permissions hide relations the public role should not see, and that the response format matches the client code. Record the chosen depths and populate objects in the repository next to the schema, so a later change to a relation is tested against the same routes.
Record the schema and test cases for review
Commit the final content type definitions, the owning-side and inverse decisions, the populate patterns and the editor and API test cases into the project repository. Ask a second engineer to review the schema and run the test cases on a fresh database. Done when the review finds no undocumented relation, every route has a recorded populate pattern, and the tests pass on a clean install.
Access and data risks in relation design
Relations are where content boundaries quietly break. A populate call can reach records that a flat endpoint would never expose, and an editor's link choice can pull restricted material into public responses. The cards below cover the risks to check before a relation model goes live.
Public populate exposing linked content
Permissions in Strapi are set per content type, so a public role allowed to read an article can also receive any relation that the article populates. If a related author, document or draft is not locked down on its own, a nested populate query can return it without a direct request. Review the public role for every type a populated relation points to, not only the type you query first.
Strapi SSO docsUnauthenticated nested populate tests
Before launch, send unauthenticated requests that populate several levels deep and compare each response with what the business intends the public to see. Include draft and unpublished states, private collections and fields on related entries. Record the exact query strings used so the same test can be rerun after each schema or permission change.
Editors linking restricted records
Relation fields in the admin panel usually show every entry of the target type, so an editor can link content they are not entitled to see or publish. Decide whether restricted records belong in a separate type or whether relation pickers should be filtered by role. Confirm the behavior in your Strapi version and test it with a non-admin editor account.
Inverse fields revealing hidden links
A bidirectional relation adds a field on the target side, and that field can expose which records point to it. A supplier,客户 or internal project linked to a public item may become visible through the inverse side even when the forward field is hidden. List every inverse field, decide who may read it, and remove it from public responses where the relationship itself is sensitive.
Role settings for each populated relation
Users and Permissions settings, along with admin roles, determine which fields and actions each caller receives, and they must be reviewed relation by relation. Check read permissions on the target type, field-level restrictions and any custom controller that builds its own populate query. Document the expected result per role so reviewers can confirm the matrix matches the design.
Questions teams ask about Strapi relation design
How much does outside relation design work cost?
No single figure applies, because the price follows from the written scope. The main drivers are how many content types and relations are in play, how many editor-facing workflows depend on them, how many front-end and integration consumers read the API, and whether existing content must be remodeled. Localization, draft and publish rules, and any migration from another CMS also add effort. Ask for a quote that lists the content types reviewed, the query patterns tested, the deliverables (diagram, schema changes, query guidance) and the items excluded. DeployOpen does not publish prices.
How long does a Strapi relation model review take?
Duration depends on the size of the content model and how much of it is already live. A review of a small model with a few collection types is much shorter than one covering dozens of types, dynamic zones and localized content that several channels consume. Time is also spent waiting on stakeholder availability for editor interviews. Ask the provider to tie the timeline to named inputs and review rounds in the written scope, and confirm which work happens before any schema change is made.
Can our internal team design Strapi relations without outside help?
Yes, many teams do, provided at least one engineer understands Strapi's relation types, the query behavior of populate, and how the Content-type Builder differs from code-based schema changes. Internal teams usually struggle with the editorial side: deciding which side of a relation owns the data, and which editor tasks need a reverse lookup. A practical check is whether the team can write the list of content types, relations and expected API queries and then review them with two or three editors. Outside design work is most useful when that review is skipped under deadline pressure.
What do you need from our team for a relation design review?
Three inputs carry most of the work. First, a content inventory listing every content type, its fields, its current relations and its owner. Second, sample queries from the front end and any integrations, including how deep they populate and how often they run. Third, short interviews with editors about how they create and find related entries. Also provide your current Strapi version, database, and any localization or draft and publish requirements. Missing sample queries are the most common gap, because they determine whether a deep relation graph will cause slow responses.
Can relation mistakes be fixed after launch?
Many can, but the cost rises with data volume and the number of consumers. Changing a relation from one-way to bidirectional, or from one-to-one to many, usually requires a schema change and a data migration that rewrites existing links. If front ends or integrations already depend on the populated shape, those consumers must change too. Test any correction on a copy of production data first, and confirm with your provider how rollback works for both schema and data. Catching the problem before the first content load is far cheaper.
How do relation choices affect later schema changes?
Relations are among the hardest parts of a Strapi model to change later, because they connect content types and appear in API responses and editor screens. A decision such as which side owns a relation, or whether a relation is directional, determines where the foreign key lives and which field disappears if you rename or remove it. Removing a field can also remove stored links. Plan schema changes as a release process, with a migration file that moves or backfills links before the schema sync runs, and document each relation's owner and reverse field in the model review.
Do deep relation graphs slow down Strapi responses?
They can. Each populated relation adds a query or join, and nested populates multiply the work, especially for lists of entries. Responses also grow, which affects front-end rendering and bandwidth. The practical control is to populate only the fields each consumer needs, limit nesting depth, and test the heaviest endpoints against a realistic data volume on your chosen database. Ask the reviewer to measure the slowest queries from your sample set rather than assume the model is fast enough.
How a populated request moves through relations
The flow starts with an editor linking entries in the admin panel, which the Document Service writes to the database as related documents. A front-end request then passes the API layer, where the permission check for each requested relation applies before the populate step assembles the nested response. Check that the role used by the front end can read every related type it asks for, because a populated relation the caller cannot read is dropped or blocked at this step.
Editor writes, Document Service stores, and a populated read passes the permission check.
What a relation design engagement produces
A fixed-scope relation design engagement produces a written set of deliverables agreed before work starts. The core is a relation map that lists every content type, every relation field, its target, its cardinality and whether it is one-way or bidirectional, along with the editorial reason it exists. Next comes a decision record for each relation: the chosen Strapi relation type, the reason for it, and the alternatives that were rejected, such as a component or a dynamic zone where a relation would have hidden content inside another entry. Each decision should name the field, for example author on article, so your team can trace it later in the schema files.
Front-end teams receive populate and query guidance. This covers which relations each page or API route needs, how to request them with populate and explicit field selection, and where a deep populate would pull far more data than the screen uses. Permission review notes come with it, listing which roles can read, create and change related entries through the Users & Permissions and admin role settings, and where a public read of a relation could expose drafts or internal records. The engagement also includes a test plan built on realistic content volumes, so that query depth and editor workflows are checked against data that resembles production rather than a handful of sample entries.
The effort depends mainly on the number of content types, the number of relations between them, and how many front-end, search or integration consumers read those relations. A model with a few types and one-way links is a small exercise, while a catalog with localized, multi-level relations used by several clients takes longer to map and test. Ask the provider to show the relation map and the list of consumers in the quote, and confirm which Strapi version the design targets, since the Document Service API and response format apply to the work.
How DeployOpen designs Strapi relations with your team
DeployOpen works on Strapi relations as part of a written, fixed-scope engagement inside your own infrastructure. We map the content your editors and developers need, choose relation types and directions against those queries, and hand over a model your team can maintain after launch.
How we scope
- Inventory the content types, editors and front-end pages that depend on each relation before choosing any type.
- Record which relations are one-way or bidirectional, with the reasons, in the written scope.
- Agree the query patterns and populate depth the front end needs, so relation graphs are sized to real reads.
How we build
- Model relations in a development project, using the Content-type Builder only in development as the source of schema changes.
- Build sample entries and populate queries that exercise the deepest relation paths and measure their response payloads.
- Review each relation with your team for editing effort, localization behavior and effects on later schema changes.
How we hand over
- Deliver a relation map documenting each type, direction, cardinality and the reasoning behind it.
- Provide the schema files, query examples and populate guidelines your developers need to extend the model.
- Walk your editors and developers through the model and record open questions for your own owners to confirm.
How we support
- Ongoing support, upgrades and continuous testing are available as a retainer after handover.
- Retainer work can cover reviews of new relations before they reach production through your release process.
- Confirm with DeployOpen which Strapi version and plan your environment targets before the written scope is signed.

