A Store is the top-level container in OpenFGA. Think of it as one project or one workspace. Everything for one authorization setup lives inside it, and nothing leaks out to other stores.
You need a boundary. Without one, all your rules and data would sit in a single shared pile. Stores give you clean separation.
Each store is fully isolated. A Check inside store A can never see tuples that live in store B. This lets you keep different apps, or different environments (dev, staging, production), completely apart.
A store holds three things.
| Part | What it is |
|---|---|
| Authorization models | The rules (type and relation definitions). Versioned. |
| Relationship tuples | The data. Small facts like (account:123, assignee, role:manager). |
| Assertions | Saved tests: example questions with expected answers. |
The rules. A store can hold many versions of the model over time. Each version gets its own model ID. When you change the rules, you write a new version; the old one stays. Your tuples keep working, and you can point a Check at a specific model version if you want.
The data. All the small facts like:
(account:123, assignee, role:manager)
This is usually the biggest part, sometimes millions of rows.
Saved tests. You write example questions with expected answers, like “manager should be allowed to approve → true”. They let you check that your model still behaves correctly after a change.
Every store has a unique store ID (a long string). This ID is the key to everything.
This is a design choice, not a fixed rule. Common patterns:
organization:acme vs organization:globex).<note tip> A good default: start with one store per environment, and only split further when you have a real reason. </note>