Skip to main content
MCP server CX Codex

Apple Safari — Claude Code MCP server: what it does, install

This MCP server lets an agent inspect Safari history, tabs, bookmarks, reading list, and page content. Browser writes stay off by default.

Install into Claude Code · Platform CLI All methods and platforms ↓
claude mcp add --env APPLE_SAFARI_ALLOW_WRITES=<APPLE_SAFARI_ALLOW_WRITES> --env APPLE_SAFARI_ALLOW_CODES=<APPLE_SAFARI_ALLOW_CODES> --env APPLE_SAFARI_ALLOW_NETWORK=<APPLE_SAFARI_ALLOW_NETWORK> --env APPLE_SAFARI_DOWNLOAD_DIR=<APPLE_SAFARI_DOWNLOAD_DIR> --env APPLE_SAFARI_NETWORK_CHUNK_CHARS=<APPLE_SAFARI_NETWORK_CHUNK_CHARS> --transport stdio safari -- npx -y @mgcrea/mcp-apple-safari
Open on GitHub

What Apple Safari does

The server connects an agent to Safari on macOS. It can search browsing history by text or date range, resolve a history item, list open tabs, inspect bookmarks, and show saved reading-list entries. For a live page, it can return captured text or HTML and describe elements that accept clicks or input.

The data comes through three separate access paths. History, bookmarks, and the reading list use Full Disk Access. Open tabs use Apple Events, a running Safari session, and an Automation grant. Page content uses the browser extension, which must be enabled and allowed on that site. Without Full Disk Access, the history and bookmark path cannot work.

Actions are disabled by default. APPLE_SAFARI_ALLOW_WRITES enables URL opening, clicks, typing, scrolling, and adding reading-list items. APPLE_SAFARI_ALLOW_CODES and APPLE_SAFARI_ALLOW_NETWORK separately enable one-time-code lookup and network capture. Passwords, card numbers, and CVC values are returned without their contents.

What it helps with

  • search Safari history by text or date range
  • list the tabs currently open in Safari
  • read a page as captured text or HTML
  • inspect bookmarks and unread reading-list items
  • identify clickable and typeable elements on a live page

Example prompts for the agent

  • Search Safari history for visits matching example and show their dates.
  • List the tabs currently open in Safari, including their URLs.
  • Read the current Safari page and identify its available input fields.

How to install Apple Safari

Platform CLI

claude mcp add --env APPLE_SAFARI_ALLOW_WRITES=<APPLE_SAFARI_ALLOW_WRITES> --env APPLE_SAFARI_ALLOW_CODES=<APPLE_SAFARI_ALLOW_CODES> --env APPLE_SAFARI_ALLOW_NETWORK=<APPLE_SAFARI_ALLOW_NETWORK> --env APPLE_SAFARI_DOWNLOAD_DIR=<APPLE_SAFARI_DOWNLOAD_DIR> --env APPLE_SAFARI_NETWORK_CHUNK_CHARS=<APPLE_SAFARI_NETWORK_CHUNK_CHARS> --transport stdio safari -- npx -y @mgcrea/mcp-apple-safari

Replace <…> with your own values

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 Safari

How do I install Apple Safari in Claude Code?

Run claude mcp add mcp-apple-safari -- npx -y @mgcrea/mcp-apple-safari, then run `claude mcp add --env APPLE_SAFARI_ALLOW_WRITES=<APPLE_SAFARI_ALLOW_WRITES> --env APPLE_SAFARI_ALLOW_CODES=<APPLE_SAFARI_ALLOW_CODES> --env APPLE_SAFARI_ALLOW_NETWORK=<APPLE_SAFARI_ALLOW_NETWORK> --env APPLE_SAFARI_DOWNLOAD_DIR=<APPLE_SAFARI_DOWNLOAD_DIR> --env APPLE_SAFARI_NETWORK_CHUNK_CHARS=<APPLE_SAFARI_NETWORK_CHUNK_CHARS> --transport stdio safari -- npx -y @mgcrea/mcp-apple-safari`.

What does Apple Safari do?

It lets an agent inspect Safari history, bookmarks, reading-list entries, open tabs, and page content. With the relevant permissions enabled, it can also inspect page controls and perform browser actions.

Which permissions does Apple Safari need?

Full Disk Access is used for history and bookmarks. Open tabs require Safari to be running with Automation access, while page content requires the extension to be enabled for the target site.

Similar MCP servers

All MCP servers for Browser and scraping →

From the same set6

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor