search-mcp
Provides web search through Brave Search, allowing search queries and result retrieval.
Provides web search through DuckDuckGo, allowing search queries and result retrieval.
Provides web search through Google, allowing search queries and result retrieval.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@search-mcp Search Google for 'MCP server security best practices' and summarize the top result."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
search-mcp
Playwright経由で検索エンジンを叩くstdio MCP。Google / Bing / DuckDuckGo / Yahoo! JAPAN / Brave Search対応。
詳しい背景・設計・検証の経緯は SPEC.md を参照。
セットアップ
git clone https://github.com/antigravity-press/search-mcp.git
cd search-mcp
uv sync
uv run playwright install chromium仮想ディスプレイの用意(headless=Falseを使う場合、オプション)
Google/DuckDuckGo/Brave等をheadlessで使う場合、bot判定回避のためheadless=False
での起動を求められることがある(下記の表を参照)。この用途では人間が画面を見る
必要は無いので、OS側に人間の接続に依存しない仮想ディスプレイさえ用意しておけば、
誰の接続にも依存せず常時headful検索が可能になる(SPEC.md 3節参照)。
用意しなくても動く(その場合はheadless専用になるだけ)。用意する場合、手段は環境
依存。Linuxサーバーの一例として、Xvfbが使えないディストロ(近年のRHEL系はWayland
移行でXvfbが標準から外れていることがある)では、weston(Waylandコンポジタ)の
headless backendでも同等のことができる:
sudo dnf install weston xorg-x11-server-Xwayland # ディストロにより異なる
mkdir -p /tmp/.X11-unix # 通常はX11パッケージが作るが無い場合は要作成
weston --backend=headless --xwayland &これで:0にX11ディスプレイが立つ。search()ツールはheadless=False指定時、
環境変数SEARCH_MCP_HEADFUL_DISPLAY(既定値:0)で指定したディスプレイを自動的に
使う。永続化したい場合はsystemdサービス化する(このリポジトリのスコープ外、
OS側の環境セットアップとして各自で行う)。
Related MCP server: Web Search MCP
How To Use(全体の流れ)
MCPセットアップ → 利用可能(空プロファイル)
├─ 検索でheadful使いたい・Google/DuckDuckGo/Brave等をheadlessで安全に使いたい
│ → OS側に人間の接続に依存しない仮想ディスプレイを用意する
│ (このMCPの機能範囲外、一回きりの環境セットアップ。手段は環境依存)
│ 用意済みなら誰の接続にも依存せず常時headful検索が可能
│
└─ ログイン済みプロファイルで動かしたい
├─ 既存の育ったプロファイルが手元にある → import_profileで取り込むだけ(Display不要)
└─ 無い・新規にログインしたい → bake_profileで焼き込み
(ここでのheadfulは人間が操作できる本物のDisplayが必要、SSH X11フォワーディング/CDP等)「検索フェーズのheadful」(bot判定回避目的、人間が見る必要なし)と「焼き付けフェーズのheadful」(人間が実際に操作する)は、要求がまったく別物。前者は仮想ディスプレイで完結し、後者は本物の(人間から見える)ディスプレイが要る
プロファイルは
defaultのみでも運用できる(空のまま使い始めて、必要に応じて育てる/インポートする)。複数プロファイルの使い分けは任意
使い方(ツール)
search(query, engine="google", profile="default", num_results=10, headless=True)— 検索を実行fetch_page(url, profile="default", headless=True)— 検索結果の深掘り用に本文を取得list_profiles()— 保持しているプロファイルの一覧import_profile(source_dir, name, overwrite=False)— 既存のログイン済みプロファイルを取り込むbake_profile(profile, method="auto", start_url=None, ...)— プロファイルへのログイン等を焼き付ける(SPEC.md 4節)
エンジンごとのheadless/headfulブロック状況(2026-09-05実地検証)
profileの育ち具合(ログイン等で使い込まれているか、作成直後で無履歴か)によって、
headlessで安全に使えるかどうかが変わる。詳細はSPEC.md 8節参照。
エンジン | 育ったprofile, headless | 育ったprofile, headful | 新規profile, headless | 新規profile, headful |
✅ OK | ✅ OK | ❌ ブロック | ✅ OK | |
Bing | ✅ OK | 未検証 | ✅ OK | ✅ OK |
Yahoo! JAPAN | ✅ OK | 未検証 | ✅ OK | ✅ OK |
DuckDuckGo | ❌ ブロック | ✅ OK | ❌ ブロック | ✅ OK |
Brave | ❌ ブロック | ✅ OK | ❌ ブロック | ✅ OK |
運用の指針:
Bing/Yahoo! JAPANはどちらの状態でもheadlessで問題ない
Google/DuckDuckGo/Braveをheadlessで使うには、ログイン等で育ったprofileが実質必須。新規profileはまずheadfulで使い始めるか、
import_profileで既存の育ったprofileを取り込むことDuckDuckGo/Braveは育ったprofileでもheadlessだと即ブロックされる。常にheadful推奨(人間の接続に依存しない仮想ディスプレイがOS側にあれば、人間の接続なしに常時利用可能)
Claude Codeへの登録
claude mcp add search-mcp --scope user -- /path/to/search-mcp/.venv/bin/search-mcpAvailable Tools
5 toolsbake_profileBake ProfileA
プロファイルに新しい状態(ログイン等)を焼き付ける。headfulでブラウザを起動し、
ユーザーがウィンドウを閉じるまで待機する(SPEC.md 4節)。
method: "auto"(既定、$DISPLAYの有無で自動判定)/ "display"(ディスプレイに直接表示。
SSHのssh -X経由でも可) / "cdp"(ディスプレイが無い環境向け。Remote Debugging
ポートを開き、手元のブラウザからリモート操作する)
start_url: 最初に開くURL(例: ログインページ)。省略時は白紙タブ
cdp_host/cdp_port: method="cdp"時のbind先。閉域網内のアドレスを明示的に指定すること
timeout_seconds: この時間ブラウザが閉じられなければタイムアウトして強制終了する
Inputs: method, profile, cdp_host, cdp_port, +2 more. Returns: result
fetch_pageFetch PageA
searchの結果など、指定URLの本文をブラウザ経由(永続プロファイル使用)で取得する。
素のHTTP取得と異なり、ログイン状態やJSレンダリングが必要なページにも対応できる。 スニペットだけでは判断できない結果を、必要な数件だけ選んで深掘りする用途を想定。
Inputs: url (required), profile, headless. Returns: object
import_profileImport ProfileB
既存の(すでにログイン状態を持つ)ブラウザプロファイルフォルダをコピーして取り込む。
Inputs: source_dir (required), name, overwrite. Returns: result
list_profilesList ProfilesA
保持しているプロファイルの一覧(名前・サイズ)を返す。
Inputs: no named parameters. Returns: result
searchSearchA
検索エンジンで検索し、タイトル/URL/スニペットのリストを返す。
engine: "google"(既定)/ "bing" / "duckduckgo" / "yahoo" / "brave"。 duckduckgo・braveはheadless=Falseでの利用を推奨(headlessだと botチャレンジが出やすいことを実地検証済み)。yahooはGoogleの ライセンス提供のため実質Googleと同じ結果になる (Googleがブロックされた際の避難先として使う想定)。 profile: 使用するプロファイル名。list_profiles で確認できる。 headless: デフォルトはTrue(検証済み)。False時は専用の非公開仮想ディスプレイ (weston-headless.service)を自動的に使うため、呼び出し元が$DISPLAYを 用意する必要はない(SPEC.md 3節)。
Inputs: query (required), engine, profile, headless, +1 more. Returns: result
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 5 tools
The tools are generally distinct: search returns SERP listings, fetch_page retrieves a specific page body, and the profile tools manage browser profiles. The only mild ambiguity is between import_profile and bake_profile, since both modify the profile set, but their descriptions clearly separate copying an existing profile from creating a new state interactively.
Most tools follow a clear verb_noun pattern: list_profiles, import_profile, fetch_page, bake_profile. The lone search tool is a bare verb rather than search_web or similar, but the overall naming style is consistent and predictable.
Five tools is well-scoped for a search-oriented MCP server. Each tool covers a distinct part of the workflow: querying search engines, inspecting profiles, importing profiles, fetching pages, and baking profile state.
The core search-and-fetch workflow is well covered, and profile management includes listing, importing, and baking. A minor gap is the lack of a profile deletion or removal tool, but this does not block the main search/fetch use case.
Maintenance
Related MCP Connectors
Web search, browser automation, scraping, crawling and CAPTCHA solving for AI agents.
Playwright browser automation — navigate, click, fill forms, extract, screenshot — 17 agent tools.
Web search, scraping, crawling, research, a browser agent, and company and people data.
A real browser for your agent: screenshots, page checks, Markdown and PDFs.
Related MCP Servers
- AlicenseNot gradedqualityFmaintenanceEnables web search across Bing, DuckDuckGo, and Google using Playwright automation, with tools for retrieving search results and extracting page text content.12 npmMIT
- AlicenseNot gradedqualityDmaintenanceEnables web searching through Google, DuckDuckGo, and Bing using a headless Chrome browser, returning structured results with titles, URLs, and snippets. Also supports fetching and extracting text content from any webpage.16MIT
- AlicenseNot gradedqualityDmaintenanceEnables comprehensive web searching and content extraction using multiple search engines (Bing, Brave, DuckDuckGo) without API keys. Provides tools for full web searches with content extraction, quick search summaries, and single webpage content retrieval.1,202MIT
- AlicenseNot gradedqualityBmaintenanceProvides web search and page fetch capabilities using a browser-based approach, enabling LLMs to search DuckDuckGo, Google, or Yandex and retrieve rendered HTML from URLs.5MIT