Kagi MCP Server
Provides web search capabilities using the Kagi search API.
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
Kagi MCP Server (Node.js)
A Node.js implementation of the Kagi MCP server that provides web search capabilities to AI assistants using the Kagi search API.
Features
Web search using the Kagi API
Support for multiple search queries in parallel
Formatted search results
Built with TypeScript and the official MCP SDK
Pre-built and ready to use (no build step required)
Unique tool name (
kagi_web_search) to avoid conflicts with other MCP servers
Related MCP server: MCP Search Server
Setup Instructions
Before anything, ensure you have access to the search API. It is currently in closed beta and available upon request. Please reach out to support@kagi.com for an invite.
Prerequisites
Node.js 18 or higher
Kagi API key
Quick Start (No Installation)
You can run the server directly without installing it using npx:
KAGI_API_KEY=your_api_key_here npx github:elliottlawson/kagi-mcp-serverInstallation
Clone the repository:
git clone https://github.com/elliottlawson/kagi-mcp-server.git
cd kagi-mcp-serverRun directly (no build required):
KAGI_API_KEY=your_api_key_here node build/index.jsIf you want to modify the code, you'll need to install dependencies and rebuild:
npm install
npm run buildSetup with Claude Desktop
Add the following MCP config to your Claude Desktop configuration:
{
"mcpServers": {
"kagi": {
"command": "npx",
"args": ["github:elliottlawson/kagi-mcp-server"],
"env": {
"KAGI_API_KEY": "YOUR_API_KEY_HERE"
}
}
}
}Alternatively, if you've cloned the repository:
{
"mcpServers": {
"kagi": {
"command": "node",
"args": ["ABSOLUTE_PATH_TO_REPO/build/index.js"],
"env": {
"KAGI_API_KEY": "YOUR_API_KEY_HERE"
}
}
}
}Setup with Cursor
Go to Cursor Settings -> MCP -> Add new MCP server
Configure your MCP:
Name: Kagi Search
Type: command
Command: npx github:elliottlawson/kagi-mcp-server
Environment Variables: KAGI_API_KEY=YOUR_API_KEY_HERE
Setup with Claude Code
claude mcp add --transport stdio kagi --env KAGI_API_KEY=YOUR_API_KEY_HERE -- npx github:elliottlawson/kagi-mcp-server
Ask an AI Assistant a Question Requiring Search
For example: "Use Kagi to search for who was time's 2024 person of the year?"
The AI will use the kagi_web_search tool to perform the search, avoiding conflicts with other search tools.
Debugging
Run the MCP Inspector to debug the server:
npx @modelcontextprotocol/inspector npx github:elliottlawson/kagi-mcp-serverOr if you've cloned the repository:
npx @modelcontextprotocol/inspector node build/index.jsThen access MCP Inspector at http://localhost:5173. You may need to add your Kagi API key in the environment variables in the inspector under KAGI_API_KEY.
Development
Project Structure
kagi-mcp-server/
├── src/
│ ├── index.ts # Main entry point
│ ├── kagi-client.ts # Kagi API client
│ └── utils/
│ └── formatter.ts # Result formatting utilities
├── build/ # Pre-built JavaScript files
│ ├── index.js # Executable entry point
│ ├── kagi-client.js
│ └── utils/
│ └── formatter.js
├── package.json
├── tsconfig.json
└── README.mdBuilding
If you make changes to the TypeScript code, rebuild the project:
npm run buildRunning
To run the server:
npm startNotes
The log level can be adjusted through the
DEBUGenvironment variableThe server uses stdio for communication with the MCP client
The repository includes pre-built JavaScript files, so no build step is required to use it
The tool is named
kagi_web_searchto avoid conflicts with other MCP servers that might have a genericsearchtool
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Provides AI assistants with access to Seltz's powerful Web Search capabilities.
Web search and page fetch for AI agents. Results come from a shared cache; cached calls cost less.
The best web search for your AI Agent
Web search, Google SERP, page extraction to markdown and cited answers for AI agents.
Related MCP Servers
- MIT
- AlicenseNot gradedqualityDmaintenanceProvides web search functionality for the Gemini Terminal Agent, handling concurrent requests and content extraction to deliver real-time information from the web.Apache 2.0
- AlicenseNot gradedqualityDmaintenanceEnables web search across multiple search engines (DuckDuckGo, Bing, Startpage) with parallel execution and result deduplication. Also provides web page content extraction capabilities.2MIT
- AlicenseNot gradedqualityBmaintenanceFree web search and page fetching for AI agents. No account or API key required. Connect to https://search.parallel.ai/mcp over Streamable HTTP. Tools: web_search and web_fetch. Free-tier rate limits apply.32MIT