Apple Files — Claude Code MCP server: setup
This MCP server lets an agent inspect and manage local macOS files inside approved roots. Use it when file access from a coding client needs clear boundaries.
claude mcp add --env APPLE_FILES_MCP_SAFETY_MODE=<APPLE_FILES_MCP_SAFETY_MODE> --env APPLE_FILES_MCP_ALLOWED_ROOTS=<APPLE_FILES_MCP_ALLOWED_ROOTS> --transport stdio applefiles-mcp -- uvx apple-files-mcpWhat Apple Files does
Apple Files exposes local file and folder operations to an MCP client. The server limits access with APPLE_FILES_MCP_ALLOWED_ROOTS, while APPLE_FILES_MCP_SAFETY_MODE controls its safety setting. It runs through uvx apple-files-mcp over the default stdio transport.
You need macOS, Python 3.11+, and uv before starting it. Without macOS and Python 3.11+, the server will not run. macOS can apply extra restrictions even inside an approved root, so the directories passed to the server deserve a careful check.
What it helps with
- inspect files inside approved macOS folders
- manage local directories from an MCP client
- restrict server access to selected roots
- set a safety mode for file operations
Example prompts for the agent
- List the approved folders and find the project configuration file.
- Check the server with
files_healthbefore reading any file. - Create a reports folder inside an approved root and show its contents.
How to install Apple Files
Platform CLI
claude mcp add --env APPLE_FILES_MCP_SAFETY_MODE=<APPLE_FILES_MCP_SAFETY_MODE> --env APPLE_FILES_MCP_ALLOWED_ROOTS=<APPLE_FILES_MCP_ALLOWED_ROOTS> --transport stdio applefiles-mcp -- uvx apple-files-mcpReplace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from apple-files-mcp <command>
Platform CLI
codex mcp add applefiles-mcp --env APPLE_FILES_MCP_SAFETY_MODE=<APPLE_FILES_MCP_SAFETY_MODE> --env APPLE_FILES_MCP_ALLOWED_ROOTS=<APPLE_FILES_MCP_ALLOWED_ROOTS> -- uvx apple-files-mcpReplace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from apple-files-mcp <command>
Config file
{
"mcpServers": {
"applefiles-mcp": {
"command": "uvx",
"args": [
"apple-files-mcp"
],
"env": {
"APPLE_FILES_MCP_SAFETY_MODE": "<APPLE_FILES_MCP_SAFETY_MODE>",
"APPLE_FILES_MCP_ALLOWED_ROOTS": "<APPLE_FILES_MCP_ALLOWED_ROOTS>"
}
}
}
}Replace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from apple-files-mcp <command>
Config file
{
"servers": {
"applefiles-mcp": {
"type": "stdio",
"command": "uvx",
"args": [
"apple-files-mcp"
],
"env": {
"APPLE_FILES_MCP_SAFETY_MODE": "<APPLE_FILES_MCP_SAFETY_MODE>",
"APPLE_FILES_MCP_ALLOWED_ROOTS": "<APPLE_FILES_MCP_ALLOWED_ROOTS>"
}
}
}
}Replace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from apple-files-mcp <command>
Platform CLI
gemini mcp add -e APPLE_FILES_MCP_SAFETY_MODE=<APPLE_FILES_MCP_SAFETY_MODE> -e APPLE_FILES_MCP_ALLOWED_ROOTS=<APPLE_FILES_MCP_ALLOWED_ROOTS> applefiles-mcp uvx apple-files-mcpReplace <…> with your own values. uvx runs the command named after the package; if the README names another one, use uvx --from apple-files-mcp <command>
Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about Apple Files
How do I install Apple Files in Claude Code?
Install uv, then run claude mcp add apple-files-mcp -- uvx apple-files-mcp. Restart Claude Code after installation.
What does Apple Files do?
It gives an MCP client access to local macOS files and folders, limited to the roots you approve.
Which settings control file access?
Set APPLE_FILES_MCP_ALLOWED_ROOTS for permitted directories and APPLE_FILES_MCP_SAFETY_MODE for the safety setting. macOS may request additional permissions.