Safari MCP: Native Browser Automation for AI Agents on macOS
MCP

Safari MCP: Native Browser Automation for AI Agents on macOS

13 min read

Safari MCP is a free, open-source tool (under the MIT license) that lets an AI assistant drive the Safari browser on your Mac — no need to install or run Chrome. It comes with 80 built-in browser actions, uses 60% less of your Mac’s processing power than Chrome on Apple Silicon, and reacts almost instantly (about ~5ms per action). It works quietly in the background, so Safari never jumps in front of whatever you’re doing, and it uses your real Safari — the browser where you’re already signed in to Gmail, GitHub, and Slack. It plugs into Claude Code, Cursor, Windsurf, and any other AI assistant built to work with tools like this. (MCP is just the shared standard that makes that plugging-in possible.)

Almost every tool that lets an AI assistant control a browser — Playwright, Chrome DevTools, Browserbase — needs Chrome to do it. On a Mac, that means quietly opening a second copy of Chrome’s engine in the background. It swallows 200-400MB of memory, gets your fans spinning, and keeps a whole extra browser running that you probably never use otherwise.

Safari MCP takes a different approach: it just uses the browser you already have open.

July 2026 Update — Apple Just Shipped Its Own Safari MCP Server

On July 1, 2026, Apple released Safari Technology Preview 247 with an official, built-in MCP server — announced on the WebKit blog. If you searched “Safari MCP” and landed here, here’s how the two relate:

  • Apple’s Safari MCP server is aimed at web developers debugging their own sites: it gives agents access to the DOM, network requests, screenshots, and console output so they can find Safari compatibility issues, analyze performance, and check accessibility. It runs locally, makes no network calls of its own, and currently ships only in Safari Technology Preview — Apple’s separate developer build — not in the Safari you use every day.
  • The open-source Safari MCP covered in this article is aimed at automation: 80 tools that drive your real, everyday Safari — the one with your logins and sessions — to fill forms, manage tabs, extract data, and run multi-step workflows.

The two are complementary: Apple’s server inspects pages; this one operates the browser. And Apple building MCP support directly into Safari is the strongest validation yet of the approach this project bet on in early 2026 — native Safari access for AI agents, no Chrome required.

Q2 2026 Update — What Changed for Browser Automation in 2026

Three things changed in the second quarter of 2026 that make this tool even more useful now than it was when it first came out:

  • Running AI got 40-60% cheaper (Q2 2026) — Newer, lighter AI models like Claude Haiku 4.5 ($0.80/1M input, $4/1M output) and GPT-4o-mini brought the price way down. That matters because letting an AI browse for you means running it over and over in a loop — look at the page, decide what to do, do it, then look again. Those repeated steps used to add up fast. A 50-step test that ran an AI through a whole checklist cost about $0.50 in late 2025; today the same job runs about ~$0.20. Sources: Anthropic Pricing, OpenAI Pricing.
  • Browsers started building in AI (early 2026) — Chrome added an “AI Assistant” panel powered by Gemini, and Edge now has Copilot built right in. But here’s the catch: those built-in helpers still need a separate AI assistant on your own computer to actually click and type on the page for them. Safari MCP is exactly that piece — and it does the work inside your own logged-in Safari, so your cookies, sign-ins, and extensions all stay put. That fits neatly with how people using Comet, Atlas, and Edge’s AI features already work.
  • The wider toolkit grew up (Q2 2026) — There are now official, well-supported tools of this kind from big names like Anthropic, GitHub, and Cloudflare. And when you pair this Safari tool with n8n’s Memory Tools (added in n8n version 1.115, released April 2026 — n8n release notes), you can set up a “browse the web, remember what you found, act on it later” routine in about 30 minutes. Building the same thing before meant hand-writing a custom Python program with Playwright.

Bottom line: In 2026, AI assistants really do click around real websites for you — and on a Mac, the cheapest way to let them do that is to use the browser you already know and trust. Safari MCP is built for exactly that.

What is MCP?

“MCP is an open protocol that standardizes how applications provide context to LLMs. Think of MCP like a USB-C port for AI applications.” — Anthropic, Introducing the Model Context Protocol

Model Context Protocol, or MCP, is a shared standard for letting AI assistants use outside tools. Think of it like a standard plug and socket: any AI assistant that “speaks” MCP can plug into any tool that also speaks it, and use whatever that tool can do. So when your AI coding helper needs to open a web page, fill in a form, or grab a screenshot, it hands that request to a tool like this one. The tool does the job and passes the result back. If AI assistants are new to you, we wrote a practical guide to AI agents for small business that explains what they actually do and how to set one up.

🤖 AI assistant needs the browsere.g. "open this page and fill the form"
🔌 Safari MCP receives the requestspeaks the shared MCP standard
🍎 AppleScript drives Safarinavigate · click · type · screenshot
↩️ Result handed back to the AI

“Safari uses WebKit, the open source web rendering engine that Apple developed and uses across its operating systems.” — Apple Safari Developer page

Most tools of this kind control Chrome, either through a built-in back channel Chrome offers (its “DevTools Protocol”) or through Playwright. Safari MCP works differently: it controls Safari itself using AppleScript — the simple automation language that already comes with every Mac — helped by a small program that stays running quietly in the background so it’s always ready to respond.

Why Safari Instead of Chrome?

“Safari delivers up to 60% faster JavaScript performance than Chrome on Apple Silicon, while using significantly less memory and power.” — Apple, “Safari is faster”

“AppleScript is a scripting language created by Apple Inc. that facilitates automated control over scriptable applications on the macOS operating system.” — Apple Developer, AppleScript Overview

The practical differences matter for daily use:

Performance

It carries out each command in about ~5ms — faster than the blink of an eye — because a small helper is always running and ready, so nothing has to start up first. And on Apple Silicon Macs, the engine behind Safari uses roughly 60% less of your computer’s processing power than Chrome does to show the same pages. In everyday terms, that means less heat and a battery that lasts longer.

Your Real Browser

Chrome-based tools open a brand-new, empty browser every time — no accounts, no saved sign-ins, nothing. Every task starts from a blank slate, as if you’d never logged in anywhere.

Safari MCP uses your actual Safari — Gmail, GitHub, Slack, Ahrefs, whatever you’re already signed in to. Your AI assistant browses as you, staying logged in to everything you are.

No Focus Stealing

With the Chrome-based tools, every single action yanks the window in front of you. You’re typing away in your editor and Chrome suddenly pops up and grabs your attention. It’s a well-known annoyance for people using AI browser tools.

Safari MCP does all its work out of sight. Safari stays where it is and never jumps in front of you unless you ask it to.

Safari MCP by the Numbers

Here are the speed and popularity numbers behind the tool. The speed numbers come from our own testing on Apple Silicon (M-series) Macs; the popularity numbers are as of May 2026:

🍎 ~60% less
processing power vs Chrome on Apple Silicon
⚡ ~5ms
per action, thanks to the always-ready helper
🧰 80 tools
ready-made browser actions out of the box
🆓 $0
open-source, MIT license, no usage limits
  • Ready-made browser actions: 80 — things like moving between pages, filling forms, taking screenshots, watching network activity, saving data, and checking accessibility
  • Processing power used on Apple Silicon: in our testing, about 40% of what’s available versus Chrome’s roughly 100% — so around 60% less
  • How fast it reacts: about ~5ms in our tests, thanks to that always-ready background helper — compared with the usual ~50-200ms for Playwright and ~30-150ms for Chrome DevTools MCP
  • Memory it doesn’t use up: 200-400MB — the extra chunk of memory that the second copy of Chrome’s engine demands in the Chrome-based tools
  • Share of browser jobs it can handle: about ~95% in our experience — the last ~5% (things like Lighthouse audits and testing across different browsers) still need Chrome
  • Times it interrupts you: 0 — it’s built to work entirely out of sight
  • Cost of running the AI: in our test runs, a 50-step browsing loop came to about $0.20 using Claude Haiku 4.5
  • Price: $0 — free and open-source under the MIT license, with no access keys to buy and no usage limits
  • How many people use it: 67 GitHub stars and 3,700+ downloads a month (May 2026)
  • What setup takes: one small block of settings plus flipping 2 switches on your Mac, and it works across 5 supported AI assistants

Quick Setup

To connect Safari MCP, you paste a small block of settings into your AI assistant — this is what tells it the tool exists and how to start it. Copy the lines below into your assistant’s settings file (don’t worry about understanding each line; it just names the tool and how to run it):

👨‍💻 Show the code (for developers)
{
  "mcpServers": {
    "safari": {
      "command": "npx",
      "args": ["-y", "safari-mcp"]
    }
  }
}

Or, if you’d rather skip the copy-paste, use the one-click install buttons for VS Code and Cursor.

The last step is to give Safari and your editor permission to work together. It’s two quick toggles:

  1. In Safari, open the Develop menu and turn on “Allow JavaScript from Apple Events” (this lets other apps run small commands on the page)
  2. In System Settings, allow your editor to control (“Automate”) Safari

That’s it. Your AI assistant can now browse in Safari.

What Can It Do? (80 Tools)

The tool comes with 80 actions, grouped into these kinds:

Navigation & Tabs — Open web addresses, work with tabs, go back and forward, and refresh. Tabs are handled safely: the AI keeps track of the tabs it opened itself and never disturbs the ones you’re using.

Page Interaction — Click things, fill in forms, type, hover, drag, and scroll. It can even click the way a real person would, which some sites insist on before they’ll respond.

Data Extraction — Pull information off a page: the text, the links, tables, images, and behind-the-scenes details. It can also read how a page is styled and lay out its structure in a tidy form the AI can work with.

Screenshots & Visual — Take a picture of the whole page or just one part of it. It can also pretend to be a phone or tablet so you can check how a page looks on smaller screens.

Network & Performance — Watch what a page quietly loads in the background, feed it fake responses for testing, slow the connection down on purpose, and measure how fast the page loads.

Storage & State — Read and change the little bits of data a site saves on your machine to remember you (cookies and the like), and save or reload a snapshot of all of it.

Accessibility — Lay out the whole page the way a screen reader would see it, so you can check that your site works for people with disabilities and meets WCAG, the web’s accessibility standard.

Framework Support

Today’s websites are usually built with tools like React, Vue, and Angular, and they have a quirk: they don’t trust text that just appears in a field on its own. If a tool quietly drops text into a box, the site often doesn’t notice, so the form ends up looking empty. Safari MCP knows how to talk to each of these tools in the way it expects, so the text actually registers:

  • React — Gently resets what React is watching for, so it accepts the text as if a person had typed it
  • Vue.js — Sends Vue the exact signal it’s listening for so it picks up the change
  • Angular — Sends both of the signals Angular needs before it will accept what was entered
  • ProseMirror / Draft.js / Slate / Lexical — For the fancier text boxes (the kind where you can make text bold or add links), which ignore text that isn’t typed by a real person, it uses the same copy-and-paste your keyboard would. Our deep-dive on why these tools quietly fail on rich-text boxes explains the safety rule that trips up automation on LinkedIn, Notion, and Google Docs.
  • Shadow DOM — Reaches into the sealed-off parts of a page that live inside self-contained building blocks — spots that most tools simply can’t get to

Safari MCP vs Playwright vs Chrome DevTools MCP

FeatureSafari MCPPlaywrightChrome DevTools MCP
Browser engineNative WebKit (Safari)Chromium/Firefox/WebKitChromium
CPU usage on Apple Silicon~40% baseline~100% baseline (Chrome)~100% baseline (Chrome)
Real user sessions (cookies/logins)✅ Yes — your actual Safari❌ Fresh profile❌ Fresh profile
Focus stealing❌ Never — background⚠️ Sometimes⚠️ Frequently
Command latency~5ms (persistent osascript)~50-200ms~30-150ms
Setup complexityOne JSON line + 2 togglesnpm install + browsersChrome flags + DevTools
LicenseMIT (open-source)Apache 2.0 (Microsoft)MIT (Google)
Tool count80 native tools~40 built-in~30 built-in
Lighthouse audits❌ Not supported⚠️ Via API✅ Native
Cross-browser testing❌ Safari only✅ Chrome/Firefox/WebKit❌ Chrome only
Rich-text editors (Lexical/ProseMirror)✅ Native paths (v2.9.4+)⚠️ Synthetic events fail⚠️ Synthetic events fail
Shadow DOM access✅ Includes closed roots⚠️ Open only⚠️ Open only
Network mocking✅ Yes✅ Yes✅ Yes
Best forDaily AI agent browsing on macOSCross-browser CI/CDChrome perf diagnostics

When to Use Chrome Instead

Safari MCP takes care of about 95% of browser jobs. For the last 5%, the Chrome DevTools tool is the better pick:

  • Lighthouse audits — a page-quality report card that only Chrome can produce
  • Chrome’s own diagnostic tools — deep reports on speed, memory use, and which parts of a page’s code actually get used
  • Testing across browsers — when you specifically need to see how a page behaves in Chrome

The two tools work well side by side. Reach for Safari MCP for your everyday browsing and testing, and switch to the Chrome DevTools tool when you need those Chrome-only checks. For a broader look at how we use automation in production, see our business automation guide, our n8n self-hosted setup guide for the orchestration layer, and our deep-dive on MCP browser automation for rich text editors. For comparing automation platforms see n8n vs Make vs Zapier. For the strategic framing of where browser-driving AI fits in a small-business stack overall, see our AI in business overview.

Open Source

Safari MCP is MIT licensed and fully open — anyone can read the code, and it’s about as free-to-use as software gets. The whole thing is just two files: safari.js, which does the actual browser work, and index.js, which lets the AI talk to it.

It’s currently sitting at 28 GitHub stars and 2,000+ downloads a month, and other people have pitched in too — sending fixes, improvements, and teaming up with folks building similar Mac tools.

Links:

Losing leads because no one's answering?

A WhatsApp bot answers, schedules, and captures leads 24/7 — from $1,000 one-time. Tell me about your business →

Get a Custom Quote

Prefer to chat? WhatsApp me · full pricing · our projects

Achiya - Business automation and bot specialist

Achiya Cohen

Business Automation Expert · Building bots since 2023

Built 50+ automation systems for businesses — WhatsApp bots, CRM integrations, and automated workflows that save hours of work every day. Specializing in n8n, Make, and WhatsApp Business API.

Ready to automate your business?

50+ businesses already save 15 hours/week. Tell me about yours — I'll show you exactly what we can automate.

Get a Custom Quote

Prefer WhatsApp? Message me →

Response within hours · No commitment

Share this article:

Frequently Asked Questions

What is Safari MCP?
It is a free, open-source helper program that lets AI assistants like Claude Code, Cursor, and Windsurf control the Safari browser on your Mac directly. It gives them 80 ready-made actions — opening pages, filling in forms, taking screenshots, watching what a page loads, and more — and it does all of this without needing to install or run Chrome or any other extra browser tool. (It speaks MCP, the shared standard AI tools use to plug into outside software.)
How does it compare to Playwright or Chrome DevTools?
It controls Safari using tools that already come built into your Mac, instead of controlling Chrome from the outside the way Playwright and Chrome DevTools do. In plain terms: it works your real Safari — the one where you're already signed in to your accounts — so nothing starts from a blank slate. And because it doesn't have to open a second browser in the background, it uses about 60% less of your Mac's processing power on Apple Silicon. The Chrome-based options have to launch Chrome every time, which eats up far more of your computer's resources.
Does it work with Claude Code?
Yes. It works with any AI assistant that supports this kind of add-on, and that includes Claude Code (both the command-line version and the VS Code extension), Cursor, Windsurf, Claude Desktop, and VS Code with Continue. Setting it up is quick — you paste one small block of settings into your assistant, and you're done.
Is it free?
Yes, completely. The code is open for anyone to see, and it's released under the MIT license, which is one of the most permissive terms out there — you're free to use it, change it, and share it however you like. There's nothing to sign up for: no access keys to pay for, no monthly fee, and no cap on how much you use it.
What macOS version does it require?
Just about any modern Mac will do — you only need a version of macOS whose Safari can be controlled by other apps, which has been standard for years. It runs equally well on the newer Apple Silicon Macs (the M1, M2, M3, and M4 chips) and on older Intel Macs. On the Apple Silicon machines you also get a nice bonus: it draws far less power than running Chrome would, so your battery lasts longer.
Can it fill forms on React and Angular sites?
Yes. Sites built with modern tools like React, Vue.js, Angular, and Svelte are picky — they often don't notice when text is typed in automatically, so the form ends up looking empty even though something was entered. This tool gets around that by nudging each site the exact way it expects, so the text actually 'sticks.' It also handles trickier cases: form fields tucked away inside self-contained page components, and rich text boxes like ProseMirror and Draft.js (the kind where you can make text bold or add links).
Chat on WhatsApp Form