How to connect Claude Code to Safari with MCP

Install TabPilot, turn on its extension in Safari › Settings › Extensions, allow it on the sites you want, and paste the one command the app shows: claude mcp add --transport http tabpilot http://127.0.0.1:47823/mcp --header "Authorization: Bearer <token>". Then run claude mcp get tabpilot: it should say ✔ Connected. Start a new Claude Code session, and Claude can use your real, signed-in Safari, asking you before anything risky.

Updated

What you need

  • A Mac with macOS 14 Sonoma or later and Safari.
  • Claude Code, installed and signed in, so the claude command works in Terminal.
  • The TabPilot app. It runs a small MCP server on your Mac at http://127.0.0.1:47823/mcp and talks to its Safari extension.

Claude Code supports MCP servers over HTTP, so it connects to TabPilot directly. No bridge, no Node.js.

Set it up, step by step

  1. Install TabPilot from the Mac App Store and open it. It needs macOS 14 Sonoma or later. The first time, it explains what is shared with the agent you connect; choose I Understand.
  2. In Safari, choose Safari › Settings › Extensions and tick TabPilot. Its button appears in Safari’s toolbar.
  3. Let the extension work on the sites you want the agent to use: click the TabPilot toolbar button on a site and allow it, or choose Always Allow on Every Website in the extension’s settings.
  4. In the TabPilot app, under Connect an agent, choose Claude Code and click Copy. The command already contains your token.
  5. Paste and press Return. Without the real token it looks like this: claude mcp add --transport http tabpilot http://127.0.0.1:47823/mcp --header "Authorization: Bearer <token>"
  6. Run claude mcp get tabpilot. It should show ✔ Connected.
  7. MCP servers load when a session starts, so open a new session and the TabPilot tools are there.

That’s all. The server keeps the name tabpilot, so in Claude Code you’ll see the tools as TabPilot’s.

Two permissions, on purpose

Safari asks you to allow every extension on each website; that’s Safari’s own rule, and it’s step 3. TabPilot then adds its own layer, Site Access, with four levels per site: Ask First (the default), Read Only, Read & Act and Off. Even with “Always Allow on Every Website” turned on in Safari, a new site asks you before the agent sees it.

What the command does

claude mcp add --transport http tabpilot http://127.0.0.1:47823/mcp \
  --header "Authorization: Bearer <token>"
  • claude mcp add adds an MCP server to Claude Code.
  • --transport http says the server speaks MCP over HTTP (Streamable HTTP), not as a program Claude Code starts.
  • tabpilot is the name the server gets in Claude Code.
  • http://127.0.0.1:47823/mcp is TabPilot’s server. 127.0.0.1 means “this Mac”: other computers can’t reach it.
  • --header "Authorization: Bearer …" sends your token with every request. TabPilot refuses requests without it.

Run it once. Claude Code remembers the server. If you later click New Token… in the app, every old setup stops working: remove the server with claude mcp remove tabpilot and paste the new command.

Example prompts

You don’t need special wording. Ask for the result you want, and mention Safari or your tabs so Claude knows to use the browser.

  • “Look at my open Safari tabs and tell me which ones I can close.”
  • “Read the article in my current tab and give me the three main points.”
  • “Open tabpilot.shop/demo, fill in the checkout with the name Demo Shopper and place the order.” (A practice page; nothing is real.)
  • “In the shop tab, find the order from last week and tell me its delivery status.”
  • “I sent you a link with Send to Agent. Open it and compare the prices with the page I’m on.”

For sites where you only want answers, set Site Access to Read Only: Claude can read but not click or type there.

What you see in Safari

TabPilot shows you what the agent does, right in the page. The first time Claude reaches a site on Ask First, Safari shows this:

The Site Access prompt. Read Only lets the agent read but never click or type on that site.

While Claude works, a blue cursor moves to each element with a caption such as Clicking “Continue”, and a pill at the bottom says TabPilot is controlling this tab with a Stop button. When Claude reaches for something that buys, pays, sends, deletes or submits, it stops and asks:

Nothing happens until you choose. If you don’t answer in time, the click doesn’t happen and Claude is told so.

When a step is yours, such as a sign-in or a two-factor code, Claude uses Take Over: a banner says your agent is waiting, you do the step yourself, and press Done (or I Can’t). Password, card and one-time-code fields get a Hidden from agent badge: Claude never gets what’s in them when it reads the page, and it can’t type into them.

To stop Claude at any moment: click Stop in the pill, turn on Stop agent in the TabPilot toolbar popover, or press Option-Shift-P. Everything Claude did is listed under Activity in the popover and the app.

The tools Claude gets

TabPilot gives the agent a fixed set of tools. None of them runs JavaScript that the agent writes.

ToolWhat it does
list_tabsLists your open Safari tabs with their titles, addresses and Site Access level.
open_tabOpens a page in a new tab. Tabs the agent opens are marked as its own.
navigateLoads an address in a tab, or goes back, forward or reloads.
read_pageReads the page as text, with short references (like e12) to links, buttons and fields.
findFinds text and elements on the page.
clickClicks an element. You see TabPilot’s blue cursor move to it.
type_textTypes into a field. It refuses password, card and one-time-code fields.
select_optionChooses an option in a menu.
scroll / press_key / wait_forScrolls, presses keys like Enter or Escape, and waits for text to appear.
screenshotTakes a picture of the visible part of a tab.
highlightPoints something out to you with a short note.
ask_userTake Over: asks you to do a step yourself, such as a sign-in, and waits until you press Done.
get_user_notesReads what you sent it with right-click › Send to Agent.
close_tabCloses a tab the agent opened. It can’t close your own tabs.
tabpilot_statusSays whether the Safari extension is connected and whether you stopped the agent.

If something doesn’t work

  • “The Safari extension is not connected”: open the TabPilot app and check that the extension is on in Safari › Settings › Extensions.
  • “Safari has not given TabPilot access to this website”: allow the site from the TabPilot toolbar button, or choose Always Allow on Every Website.
  • A tab doesn’t respond: it was probably open before TabPilot was installed or updated. Reload it.
  • claude mcp get tabpilot doesn’t say Connected: make sure the app is open, and that the command has the current token.

More fixes are on the support page.

Questions

Do I have to run the command in every project?

By default claude mcp add adds the server for the project folder you run it in. To use TabPilot in every project, add --scope user after add. To remove it again: claude mcp remove tabpilot.

Claude Code says Connected but has no Safari tools

MCP servers load when a session starts. Start a new Claude Code session after adding TabPilot.

Is the token a secret?

Yes. It works only on this Mac, but anyone with it could control your Safari through TabPilot. Don’t paste it into shared files or chats. If it leaks, click New Token… in the app and add TabPilot again.

Does the TabPilot app need to stay open?

Yes. The app runs the server that Claude Code talks to. Quit it, and the tools stop working until you open it again.

More guides

TabPilot — MCP for Safari

Let your agent use your real Safari, with per-site access and your approval before anything risky.

Coming soon to the Mac App Store

One-time purchase · macOS 14 Sonoma or later · Try the demo store