.mintignore file to exclude files and directories from your Mintlify build process. This is useful for keeping your documentation clean by excluding drafts, temporary files, or other content you don’t want to publish.
Creating a .mintignore file
Create a .mintignore file in the root of your documentation repository, next to your docs.json file.
Syntax
The.mintignore file follows the same syntax as .gitignore files. Each line specifies a pattern for files or directories to exclude.
.mintignore
Pattern rules
- Comments: Lines starting with
#are treated as comments - Empty lines: Blank lines are ignored
- Directories: End patterns with
/to match directories - Wildcards: Use
*to match any characters - Negation: Start patterns with
!to negate a previous ignore pattern
Default ignored files
Mintlify automatically ignores the following files and directories, even without a.mintignore file:
.git.github.claude.agentsnode_modules
.mintignore file.
Examples
Exclude draft content
.mintignore
Exclude work-in-progress files
.mintignore
Exclude internal documentation
.mintignore
Exclude specific file types
.mintignore
Local development
When runningmint dev, changes to your .mintignore file require restarting the development server to take effect.
After modifying
.mintignore, restart your local development server with mint dev to apply the changes.