Users, Roles and Permissions
BookStack answers "who can do what?" in two layers, and most confusion comes from mixing them up:
- Roles say what a person can do in the system as a whole — view books, create pages, manage users.
- Item permissions say what can be done with this shelf, book, chapter or page, overriding the general answer.
The lab built both layers and tested them from the outside, as the person they restrict. This chapter follows that test.
Users
Settings → Users → Add New User is where accounts are born. A user has a name, an email (which is their login), a password, and one or more roles.
One trap, learned the hard way in the lab and written up in chapter 14: the form offers to send an invitation email instead of setting a password. If your server has no working mail — and a fresh install usually doesn't — the invite can't be sent and the whole user creation is rolled back: the form returns, no user exists, and the error log notes a failed invite. Until your mail works, untick the invite option and set a password directly.
Roles
BookStack ships with roles including Admin (everything), Editor (write and edit widely) and Viewer (read). You can add your own in Settings → Roles. A role is a long list of checkboxes — view, create, update and delete for each kind of content, plus system abilities like managing users or using the API.
The lab made a role for the job this guide cares most about: Plot Readers, with exactly four boxes ticked — view all shelves, view all books, view all chapters, view all pages — and nothing else. No create, no edit, no delete, of anything. A user holding only this role can read the library and cannot change a comma of it.
Item permissions: fencing one book
General openness with one private corner is the common real-world shape — the accounts book among the gardening books. Open the item, choose Permissions, and two things happen there:
- Turn off Inherit defaults, so this item stops taking the role-based answer.
- Set the grid: what everyone else gets (in the lab: nothing — no view, no create, no update, no delete), and what specific roles get (in the lab: Admin keeps all four).
Permissions flow down: a book's settings cover its chapters and pages unless those are fenced separately.
The test that matters
The lab's reader, Jamie Park, holds only Plot Readers. Signed in as Jamie:
| Attempt | Result |
|---|---|
| Open the Books list | Growing Vegetables listed; Seed Orders and Accounts absent |
| Open the pumpkins page | Reads fine |
| Open the fenced book's address directly | 404 — not found |
| Start a new page | Turned away; no draft created |
| Search | The open library only |
The 404 deserves a sentence of its own. BookStack does not say "forbidden" for things you may not see; it says "not found", because "forbidden" confirms the thing exists. A missing page and a secret page look identical from outside, and that is deliberate. When your own readers swear a book has vanished, check permissions before you check the recycle bin.
Check: after any permission change, sign in as the restricted person and repeat the attempts in the table. Admins cannot test fences from inside them.