MCP Server
Run the SDK as an MCP server and an agent gets a real, fingerprinted browser with 16 tools. Add this to your MCP client config; there is nothing else to install.
{
"mcpServers": {
"anti-detect-browser": {
"command": "npx",
"args": ["anti-detect-browser", "--mcp"],
"env": {
"ANTI_DETECT_BROWSER_KEY": "your-api-key"
}
}
}
} Works with any MCP client. The browser runs on your machine, so there are no browser-hours to buy.
The session model
This is the part worth understanding before reading the tool list. MCP tool calls are discrete: the model calls a tool, gets a result, thinks, calls another. Many browser tools start a fresh context per call, so a login performed in one call is gone by the next.
Here the browser process stays up. launch_browser returns a sessionId, and every page tool takes that id and reconnects to the same running browser. The tab you left open is the tab the next call finds. Cookies, storage and passkeys are written to the profile directory, so even a restart restores the same signed-in identity with the same fingerprint.
// 1. launch. `profile` is required; the profile is created if new.
launch_browser({ profile: "agent-01" })
// -> { sessionId, profileDir, viewUrl }
// 2. every page tool takes that sessionId
navigate({ sessionId, url: "https://example.com" })
fill({ sessionId, selector: "#email", value: "me@example.com" })
click({ sessionId, selector: "button[type=submit]" })
get_content({ sessionId })
// 3. the browser stays up between tool calls, so a later turn
// is still signed in. Close it when the task is done.
close_browser({ sessionId }) profile is required on launch_browser. There is no default. Pick a stable name per identity and reuse it, because the profile is the identity: reusing the name is what makes run 40 look like run 1 to the site.
Browser tools
Starting and stopping a browser, and finding the ones already running.
launch_browser
(profile , label?, color?, tags?, proxy?, proxyId?, headless?)
Launch a browser with a spoofed fingerprint. Creates the profile if it does not exist yet.
profile | string | required | Profile name. Also the directory name on disk. |
label | string | optional | Label text shown in the browser window. |
color | string | optional | Theme colour in hex, for example #e74c3c. |
tags | array | optional | Tags stored with the profile. |
proxy | string | optional | Your own proxy URL: protocol://user:pass@host:port |
proxyId | string | optional | Managed proxy id. Activates it and meters monthly quota. Get one from list_proxies or claim_proxy. |
headless | boolean | optional | Run without a visible window. |
close_browser
(sessionId )
Close one browser session.
sessionId | string | required | The id returned by launch_browser. |
list_sessions
( )
List every browser session currently running.
Page tools
All of these act on an open session, so every one of them takes a sessionId.
navigate
(sessionId, url )
Navigate to a URL.
sessionId | string | required | |
url | string | required | URL to navigate to. |
click
(sessionId, selector )
Click an element.
sessionId | string | required | |
selector | string | required | CSS selector of the element to click. |
fill
(sessionId, selector, value )
Fill a form field with text.
sessionId | string | required | |
selector | string | required | CSS selector of the input. |
value | string | required | Text to fill. |
get_content
(sessionId , selector?)
Read text content from the page, or from one element.
sessionId | string | required | |
selector | string | optional | Restrict to one element. Omit for the whole page. |
screenshot
(sessionId )
Screenshot the current page.
sessionId | string | required |
evaluate
(sessionId, script )
Run JavaScript in the page context and return the result.
sessionId | string | required | |
script | string | required | JavaScript to execute. |
Profile tools
Profiles are directories on your own disk and are unlimited on every plan, including Free.
list_profiles
( )
List local profiles.
create_profile
(name )
Create a profile and fix its fingerprint now, rather than at first launch. The engine generates a coherent fingerprint automatically.
name | string | required | Profile name. |
delete_profile
(name )
Delete a profile and its data from disk.
name | string | required | Profile name. |
Proxy tools
Managed residential proxies come with paid plans. Claiming one is free; quota is consumed only when you launch a profile with it.
list_proxies
( )
List the managed proxies assigned to you, plus your monthly quota: limit, usedThisMonth, remaining, holdCount and holdCap.
claim_proxy
( )
Claim an available managed proxy and return it, including its id. Claiming does not consume monthly quota.
Live View tools
Stream a running session to your dashboard. Live View is a paid-plan feature.
start_live_view
(sessionId , quality?)
Start streaming the session screen.
sessionId | string | required | |
quality | number | optional | JPEG quality, 1 to 100. Defaults to 60. |
stop_live_view
(sessionId )
Stop streaming.
sessionId | string | required |
Common errors
| Missing required parameter "profile" | |
launch_browser has no default profile. Pass one, and use the same name every time for that identity. | |
| Session not found | |
The sessionId refers to a browser that has been closed. Call list_sessions to see what is running, or launch again. | |
| Concurrency limit reached | |
| Your plan caps how many browsers run at once: 1 on Free, then 5, 20 or 100. Close a session or raise the cap. Profile count is never the limit. |
Prefer writing code to using MCP tools? The same profiles are drivable from the SDK with standard Playwright.