Fire in da houseTop Tip:Paying $100+ per month for Perplexity, MidJourney, Runway, ChatGPT and other tools is crazy - get all your AI tools in one site starting at $15 per month with Galaxy AI Fire in da houseCheck it out free

mcp-server-macos-defaults

MCP.Pizza Chef: g0t4

The mcp-server-macos-defaults is a Model Context Protocol server designed to interface with macOS system settings through the native 'defaults' command-line utility. It provides structured access to read and write macOS user and system preferences programmatically. Key tools include listing all preference domains, searching for keys, reading specific keys or entire domains, and writing new values to settings. This server enables developers and AI agents to automate configuration management, customize environments, and query system preferences in real time on macOS devices. It integrates seamlessly with MCP clients and hosts, facilitating secure and scoped interaction with macOS defaults.

Use This MCP server To

Read macOS user and system preference settings Write or update macOS defaults programmatically Search for specific keys in macOS defaults domains List all available macOS defaults domains Automate macOS configuration management tasks

README

mcp-server-macos-defaults MCP server

MCP server for reading/writing macOS defaults (settings)

Components

Tools

  • list-domains:
    • equivalent to running defaults domains
  • find:
    • equivalent to running defaults find <word>
  • defaults-read:
    • equivalent to running defaults read <domain> <key>
    • if key is not provided, the entire domain is read
  • defaults-write:
    • equivalent to running defaults write <domain> <key> <value>

Quickstart

Install

Claude Desktop

On MacOS: ~/Library/Application\ Support/Claude/claude_desktop_config.json On Windows: %APPDATA%/Claude/claude_desktop_config.json

Development/Unpublished Servers Configuration ``` "mcpServers": { "mcp-server-macos-defaults": { "command": "uv", "args": [ "--directory", "/path/to/mcp-server-macos-defaults", "run", "mcp-server-macos-defaults" ] } } ```
Published Servers Configuration ``` "mcpServers": { "mcp-server-macos-defaults": { "command": "uvx", "args": [ "mcp-server-macos-defaults" ] } } ```

Development

Building and Publishing

To prepare the package for distribution:

  1. Sync dependencies and update lockfile:
uv sync
  1. Build package distributions:
uv build

This will create source and wheel distributions in the dist/ directory.

  1. Publish to PyPI:
uv publish

Note: You'll need to set PyPI credentials via environment variables or command flags:

  • Token: --token or UV_PUBLISH_TOKEN
  • Or username/password: --username/UV_PUBLISH_USERNAME and --password/UV_PUBLISH_PASSWORD

Debugging

Since MCP servers run over stdio, debugging can be challenging. For the best debugging experience, we strongly recommend using the MCP Inspector.

You can launch the MCP Inspector via npm with this command:

npx @modelcontextprotocol/inspector uv --directory /path/to/mcp-server-macos-defaults run mcp-server-macos-defaults

Upon launching, the Inspector will display a URL that you can access in your browser to begin debugging.

mcp-server-macos-defaults FAQ

How do I install mcp-server-macos-defaults for use with Claude Desktop?
On macOS, add the server configuration to '~/Library/Application Support/Claude/claude_desktop_config.json'. On Windows, use '%APPDATA%/Claude/claude_desktop_config.json'.
What commands does mcp-server-macos-defaults support?
It supports 'list-domains', 'find', 'defaults-read', and 'defaults-write', mirroring macOS 'defaults' CLI functionality.
Can I read an entire domain's settings with this server?
Yes, if you omit the key in 'defaults-read', the server returns the entire domain's preferences.
Is it possible to write new values to macOS defaults using this server?
Yes, the 'defaults-write' tool allows writing or updating keys with new values in specified domains.
Does mcp-server-macos-defaults support secure and scoped access?
Yes, it integrates with MCP principles to ensure secure, scoped, and observable interactions with macOS settings.
Can this server be used for automated macOS environment customization?
Absolutely, it enables programmatic control over macOS preferences for automation workflows.
How do I run the server in development mode?
Use the provided command with 'uv' and specify the directory path to the server source, as shown in the development configuration snippet.
Is this server compatible with multiple LLM providers?
Yes, it works with MCP clients that can connect to models like OpenAI, Claude, and Gemini.