Showing the first 18000 characters. Load the complete file to read the remainder.
# Payload Documentation
> Official Payload documentation, organized by major version. Match the documentation version to the installed `payload` and `@payloadcms/ui` major version.
## Documentation versions
- [Payload 3.x documentation](https://payloadcms.com/docs/v3/llms.txt): Current stable documentation. Use this for Payload 3.x projects.
- [Payload 4.x documentation](https://payloadcms.com/docs/v4/llms.txt): Beta documentation. Use this only for Payload 4.x projects.
## Complete documentation
- [Payload 3.x complete documentation](https://payloadcms.com/docs/v3/llms-full.txt): All stable 3.x documentation in one file.
- [Payload 4.x complete documentation](https://payloadcms.com/docs/v4/llms-full.txt): All 4.x documentation in one file.
## Current stable documentation
### Basics
#### Getting Started
- [What is Payload?](https://payloadcms.com/docs/v3/getting-started/what-is-payload.md): Payload is a next-gen application framework that can be used as a Content Management System, enterprise tool framework, headless commerce platform, or digital asset management tool.
- [Use Cases](https://payloadcms.com/docs/v3/getting-started/use-cases.md): Payload powers headless CMS, internal tools, headless commerce, and DAM workloads. Learn whether Payload is the right framework for your project.
- [Payload Concepts](https://payloadcms.com/docs/v3/getting-started/concepts.md): Payload is based around a small and intuitive set of concepts. Key concepts include collections, globals, fields and more.
- [Installation](https://payloadcms.com/docs/v3/getting-started/installation.md): To quickly get started with Payload, simply run npx create-payload-app or install from scratch.
#### Migration Guide
- [2.0 to 3.0 Migration Guide](https://payloadcms.com/docs/v3/migration-guide/overview.md): Upgrade guide for Payload 2.x projects migrating to 3.0.
#### Configuration
- [The Payload Config](https://payloadcms.com/docs/v3/configuration/overview.md): The Payload Config is central to everything that Payload does, from adding custom React components, to modifying collections, controlling localization and much more.
- [Collection Configs](https://payloadcms.com/docs/v3/configuration/collections.md): Structure your Collections for your needs by defining fields, adding slugs and labels, establishing access control, tying in hooks, setting timestamps and more.
- [Global Configs](https://payloadcms.com/docs/v3/configuration/globals.md): Set up your Global config for your needs by defining fields, adding slugs and labels, establishing access control, tying in hooks and more.
- [I18n](https://payloadcms.com/docs/v3/configuration/i18n.md): Manage and customize internationalization support in your CMS editor experience
- [Localization](https://payloadcms.com/docs/v3/configuration/localization.md): Add and maintain as many locales as you need by adding Localization to your Payload Config, set options for default locale, fallbacks, fields and more.
- [Environment Variables](https://payloadcms.com/docs/v3/configuration/environment-vars.md): Learn how to use Environment Variables in your Payload project
#### Database
- [Database](https://payloadcms.com/docs/v3/database/overview.md): With Payload, you bring your own database and own your data. You have full control.
- [Migrations](https://payloadcms.com/docs/v3/database/migrations.md): Payload features first-party database migrations all done in TypeScript.
- [Transactions](https://payloadcms.com/docs/v3/database/transactions.md): Database transactions are fully supported within Payload.
- [Indexes](https://payloadcms.com/docs/v3/database/indexes.md): Index fields to produce faster queries.
- [MongoDB](https://payloadcms.com/docs/v3/database/mongodb.md): Payload has supported MongoDB natively since we started. The flexible nature of MongoDB lends itself well to Payload's powerful fields.
- [Postgres](https://payloadcms.com/docs/v3/database/postgres.md): Payload supports Postgres through an officially supported Drizzle Database Adapter.
- [SQLite](https://payloadcms.com/docs/v3/database/sqlite.md): Payload supports SQLite through an officially supported Drizzle Database Adapter.
#### Fields
- [Fields Overview](https://payloadcms.com/docs/v3/fields/overview.md): Fields are the building blocks of Payload, find out how to add or remove a field, change field type, add hooks, define Access Control and Validation.
- [Fields Generated by Payload](https://payloadcms.com/docs/v3/fields/default-fields.md): Learn which fields Payload generates automatically and how to override their configuration.
- [Array Field](https://payloadcms.com/docs/v3/fields/array.md): Array Fields are intended for sets of repeating fields, that you define. Learn how to use Array Fields, see examples and options.
- [Blocks Field](https://payloadcms.com/docs/v3/fields/blocks.md): The Blocks Field is a great layout builder and can be used to construct any flexible content model. Learn how to use Block Fields, see examples and options.
- [Checkbox Field](https://payloadcms.com/docs/v3/fields/checkbox.md): Checkbox field types allow the developer to save a boolean value in the database. Learn how to use Checkbox fields, see examples and options.
- [Code Field](https://payloadcms.com/docs/v3/fields/code.md): The Code field type will store any string in the Database. Learn how to use Code fields, see examples and options.
- [JSON Field](https://payloadcms.com/docs/v3/fields/json.md): The JSON field type will store any string in the Database. Learn how to use JSON fields, see examples and options.
- [Collapsible Field](https://payloadcms.com/docs/v3/fields/collapsible.md): With the Collapsible field, you can place fields within a collapsible layout component that can be collapsed / expanded.
- [Date Field](https://payloadcms.com/docs/v3/fields/date.md): The Date field type stores a Date in the database. Learn how to use and customize the Date field, see examples and options.
- [Email Field](https://payloadcms.com/docs/v3/fields/email.md): The Email field enforces that the value provided is a valid email address. Learn how to use Email fields, see examples and options.
- [Group Field](https://payloadcms.com/docs/v3/fields/group.md): The Group field allows other fields to be nested under a common property. Learn how to use Group fields, see examples and options.
- [Number Field](https://payloadcms.com/docs/v3/fields/number.md): Number fields store and validate numeric data. Learn how to use and format Number fields, see examples and Number field options.
- [Point Field](https://payloadcms.com/docs/v3/fields/point.md): The Point field type stores coordinates in the database. Learn how to use Point field for geolocation and geometry.
- [Radio Group Field](https://payloadcms.com/docs/v3/fields/radio.md): The Radio field type allows for the selection of one value from a predefined set of possible values. Learn how to use Radio fields, see examples and options.
- [Relationship Field](https://payloadcms.com/docs/v3/fields/relationship.md): The Relationship field provides the ability to relate documents together. Learn how to use Relationship fields, see examples and options.
- [Join Field](https://payloadcms.com/docs/v3/fields/join.md): The Join field provides the ability to work on related documents. Learn how to use Join field, see examples and options.
- [Rich Text Field](https://payloadcms.com/docs/v3/fields/rich-text.md): The Rich Text field allows dynamic content to be written through the Admin Panel. Learn how to use Rich Text fields, see examples and options.
- [Row Field](https://payloadcms.com/docs/v3/fields/row.md): With the Row field you can arrange fields next to each other in the Admin Panel to help you customize your Dashboard.
- [Select Field](https://payloadcms.com/docs/v3/fields/select.md): The Select field provides a dropdown-style interface for choosing options from a predefined list. Learn how to use Select fields, see examples and options.
- [Tabs Field](https://payloadcms.com/docs/v3/fields/tabs.md): The Tabs field is a great way to organize complex editing experiences into specific tab-based areas.
- [Text Field](https://payloadcms.com/docs/v3/fields/text.md): Text field types simply save a string to the database and provide the Admin Panel with a text input. Learn how to use Text fields, see examples and options.
- [Textarea Field](https://payloadcms.com/docs/v3/fields/textarea.md): Textarea field types save a string to the database, similar to the Text field type but equipped for longer text. Learn how to use Textarea fields, see examples and options.
- [UI Field](https://payloadcms.com/docs/v3/fields/ui.md): UI fields are purely presentational and allow developers to customize the Admin Panel to a very fine degree, including adding actions and other functions.
- [Upload Field](https://payloadcms.com/docs/v3/fields/upload.md): Upload fields will allow a file to be uploaded, only from a collection supporting Uploads. Learn how to use Upload fields, see examples and options.
#### Access Control
- [Access Control](https://payloadcms.com/docs/v3/access-control/overview.md): Payload makes it simple to define and manage Access Control. By declaring roles, you can set permissions and restrict what your users can interact with.
- [Collection Access Control](https://payloadcms.com/docs/v3/access-control/collections.md): With Collection-level Access Control you can define which users can create, read, update or delete Collections.
- [Globals Access Control](https://payloadcms.com/docs/v3/access-control/globals.md): Global-level Access Control is specified within each Global's `access` property and allows you to define which users can read or update Globals.
- [Field-level Access Control](https://payloadcms.com/docs/v3/access-control/fields.md): Field-level Access Control is specified within a field's config, and allows you to define which users can create, read or update Fields.
#### Hooks
- [Hooks Overview](https://payloadcms.com/docs/v3/hooks/overview.md): Hooks allow you to add your own logic to Payload, including integrating with third-party APIs, adding auto-generated data, or modifying Payload's base functionality.
- [Collection Hooks](https://payloadcms.com/docs/v3/hooks/collections.md): You can add hooks to any Collection, several hook types are available including beforeChange, afterRead, afterDelete and more.
- [Global Hooks](https://payloadcms.com/docs/v3/hooks/globals.md): Hooks can be added to any Global and allow you to validate data, flatten locales, hide protected fields, remove fields and more.
- [Field Hooks](https://payloadcms.com/docs/v3/hooks/fields.md): Hooks can be added to any fields, and optionally modify the return value of the field before the operation continues.
- [Context](https://payloadcms.com/docs/v3/hooks/context.md): Context allows you to pass in extra data that can be shared between hooks
### Managing Data
#### Local API
- [Local API](https://payloadcms.com/docs/v3/local-api/overview.md): The Payload Local API allows you to interact with your database and execute the same operations that are available through REST and GraphQL within Node, directly on your server.
- [Using Payload outside Next.js](https://payloadcms.com/docs/v3/local-api/outside-nextjs.md): Payload can be used outside of Next.js within standalone scripts or in other frameworks like Remix, SvelteKit, Nuxt, and similar.
- [Using Local API Operations with Server Functions](https://payloadcms.com/docs/v3/local-api/server-functions.md): Learn to use Local API operations with Server Functions in Payload to manage server-side logic, data interactions, and custom workflows directly within your CMS.
- [Respecting Access Control with Local API Operations](https://payloadcms.com/docs/v3/local-api/access-control.md): Learn how to implement and enforce access control in Payload's Local API operations, ensuring that the right permissions are respected during data manipulation.
#### REST API
- [REST API](https://payloadcms.com/docs/v3/rest-api/overview.md): Payload generates a fully functional REST API from your Collection and Global configs.
#### GraphQL
- [GraphQL Overview](https://payloadcms.com/docs/v3/graphql/overview.md): Payload ships with a fully featured and extensible GraphQL API, which can be used in addition to the REST and Local APIs to give you more flexibility.
- [Adding your own Queries and Mutations](https://payloadcms.com/docs/v3/graphql/extending.md): Payload allows you to add your own GraphQL queries and mutations, simply set up GraphQL in your main Payload Config by following these instructions.
- [GraphQL Schema](https://payloadcms.com/docs/v3/graphql/graphql-schema.md): Output your own GraphQL schema based on your collections and globals to a file.
#### Queries
- [Querying your Documents](https://payloadcms.com/docs/v3/queries/overview.md): Payload provides a querying language through all APIs, allowing you to filter or search through documents within a Collection.
- [Sort](https://payloadcms.com/docs/v3/queries/sort.md): Payload sort allows you to order your documents by a field in ascending or descending order.
- [Depth](https://payloadcms.com/docs/v3/queries/depth.md): Payload depth determines how many levels down related documents should be automatically populated when retrieved.
- [Select](https://payloadcms.com/docs/v3/queries/select.md): Payload select determines which fields are selected to the result.
- [Pagination](https://payloadcms.com/docs/v3/queries/pagination.md): Payload queries are equipped with automatic pagination so you create paginated lists of documents within your app.
### Features
#### Admin
- [The Admin Panel](https://payloadcms.com/docs/v3/admin/overview.md): Manage your data and customize the Payload Admin Panel by swapping in your own React components. Create, modify or remove views, fields, styles and much more.
- [Preview](https://payloadcms.com/docs/v3/admin/preview.md): Enable links to your front-end to preview published or draft content.
- [Custom Admin Panel Location](https://payloadcms.com/docs/v3/admin/admin-panel-location.md): Learn how to move and customize the location of your Payload Admin Panel, including nested routes and custom folder structures.
- [Document Locking](https://payloadcms.com/docs/v3/admin/locked-documents.md): Ensure your documents are locked during editing to prevent concurrent changes from multiple users and maintain data integrity.
- [Accessibility](https://payloadcms.com/docs/v3/admin/accessibility.md): Our commitment and approach to accessibility within the admin panel.
- [Customizing CSS & SCSS](https://payloadcms.com/docs/v3/admin/customizing-css.md): Customize the Payload Admin Panel further by adding your own CSS or SCSS style sheet to the configuration, powerful theme and design options are waiting for you.
- [React Hooks](https://payloadcms.com/docs/v3/admin/react-hooks.md): Make use of all of the powerful React hooks that Payload provides.
- [Managing User Preferences](https://payloadcms.com/docs/v3/admin/preferences.md): Store the preferences of your users as they interact with the Admin Panel.
- [Page Metadata](https://payloadcms.com/docs/v3/admin/metadata.md): Customize the metadata of your pages within the Admin Panel
#### Custom Components
- [Swap in your own React components](https://payloadcms.com/docs/v3/custom-components/overview.md): Fully customize your Admin Panel by swapping in your own React components. Add fields, remove views, update routes and change functions to sculpt your perfect Dashboard.
- [Root Components](https://payloadcms.com/docs/v3/custom-components/root-components.md)
- [Swap in your own React Context providers](https://payloadcms.com/docs/v3/custom-components/custom-providers.md)
- [Customizing Views](https://payloadcms.com/docs/v3/custom-components/custom-views.md)
- [Dashboard Widgets](https://payloadcms.com/docs/v3/custom-components/dashboard.md): Create custom dashboard widgets to display data, analytics, or any other content in the Payload Admin Panel.
- [Document Views](https://payloadcms.com/docs/v3/custom-components/document-views.md)
- [Edit View](https://payloadcms.com/docs/v3/custom-components/edit-view.md)
- [List View](https://payloadcms.com/docs/v3/custom-components/list-view.md)
#### UI Components
- [UI Components](https://payloadcms.com/docs/v3/ui-components/overview.md): Use the React components that power the Payload Admin Panel in your own Custom Components.
- [AnimateHeight](https://payloadcms.com/docs/v3/ui-components/animate-height.md): Animate content between collapsed and expanded heights with Payload's AnimateHeight component.
- [Banner](https://payloadcms.com/docs/v3/ui-components/banner.md): Display contextual information and status messages with Payload's Banner component.
- [Button](https://payloadcms.com/docs/v3/ui-components/button.md): Use Payload's Button component for actions and navigation in Admin Panel Custom Components.
- [Card](https://payloadcms.com/docs/v3/ui-components/card.md): Group a title and related actions with Payload's Card component.
- [CodeEditor](https://payloadcms.com/docs/v3/ui-components/code-editor.md): Display and edit structured text with Payload's CodeEditor component.
- [Collapsible](https://payloadcms.com/docs/v3/ui-components/collapsible.md): Show and hide a section of content with Payload's Collapsible component.
- [CopyToClipboard](https://payloadcms.com/docs/v3/ui-components/copy-to-clipboard.md): Copy a string to the clipboard with Payload's CopyToClipboard component.
- [DatePicker](https://payloadcms.com/docs/v3/ui-components/date-picker.md): Select dates and times with Payload's DatePicker component.
- [Document Actions](https://payloadcms.com/docs/v3/ui-components/document-actions.md): Use Payload's context-aware save, publish, and bulk document actions in Admin Panel Custom Components.
- [Document State](https://payloadcms.com/docs/v3/ui-components/document-stat
Measured from the saved file
Linked document
UTF-8 text size
33.8 KB34571 bytes
Token count
7422o200k_base encoding
Markdown links
194194 distinct URLs
Fenced code blocks
0312 lines in the file
Size measures the captured UTF-8 text, not compressed transfer size. Tokens are counted with a named tokenizer; other models can count differently. Neither measure establishes context compatibility or answer quality.
Project H1
Payload Documentation
Opening blockquote
Official Payload documentation, organized by major version. Match the documentation version to the installed `payload` and `@payloadcms/ui` major version.
Context architecture
How the content is divided
3 H2 sections organize 194 parsed Markdown links. 190 links point to .md or .markdown paths; 0 link occurrences use another hostname. Linked destinations have not been recursively validated.
H2 section
Links
UTF-8 bytes
Tokens
Documentation versionsLine 5
2
271
69
Complete documentationLine 10
2
251
66
Current stable documentationLine 15
190
33782
7243
Nested indexes
2 distinct links point to other llms.txt paths. These are routes to more indexes, not proof their contents were included in this file.
Link counts exclude parsed fenced and inline code and resolve relative destinations against the final endpoint. Section sizes cover the text below each H2 until the next H2.
Embedded material
Code, installation and API examples
Fenced blocks
0 closed
Declared languages
No fenced blocks detected
Package-install commands
0 detected in fenced or inline code
Authentication examples
0 fenced lines match API-key, Authorization, Bearer, OAuth or access-token patterns
HTTP request examples
0 fenced lines match request-method patterns
Authentication links
1 links have authentication-related labels
Embedded example text and links to further documentation are counted separately. A code block does not establish that a sample runs or that an authentication flow succeeds.
Publisher prioritization
The Optional section
No H2 section named “Optional” was detected in this file.
The community proposal uses Optional by convention for secondary links that can be skipped for a shorter context. This label does not establish that everything outside it is critical, or that the material inside it is deprecated.
Machine-readable routes
MCP references and configuration text
MCP-related text was detected in the captured file. 1 links have MCP-related labels or paths. 0 fenced lines match mcpServers, mcp_servers or an mcp add command.
A verified text response establishes a companion at the checked URL. It does not prove the bundle contains all product documentation, that generation is automated, or that it fits an assistant’s context window.
Change evidence
What can be said about freshness
This capture establishes a baseline. Update frequency cannot be determined from one observation.
Linked release and migration material
3 links have release, changelog, deprecation or migration terms in their labels or paths. These provide places to investigate product changes separately.
File changes can reveal documentation edits or navigation changes. They do not by themselves measure product release velocity, accuracy, agent adoption or AI visibility.
Counts use a deterministic parser, not a spec-compliance grade. Unusual Markdown and indented code can fall outside its recognized patterns. See the llms.txt proposal and tokenizer implementation.