home / mcp / jina web search mcp server
A Model Context Protocol (MCP) server that provides tools for fetching URL content and performing web searches using the Jina AI API. Supports Docker deployment and streamable HTTP transport.
Configuration
View docs{
"mcpServers": {
"hypersniper05-jinawebsearchmcp": {
"url": "http://localhost:5003/mcp",
"headers": {
"JINA_API_KEY": "YOUR_API_KEY"
}
}
}
}You run an MCP server that exposes tools to fetch web content and perform semantic web searches using the Jina AI API. It’s designed to be easy to deploy with Docker or run directly, and it integrates with Claude Desktop and other MCP clients for convenient web access. With this server, you can fetch URL content and perform fast, semantically-aware searches from any MCP-enabled client.
Connect any MCP-compatible client to the server endpoint and use the two core tools to accomplish web-related tasks. The server runs on port 5003 and exposes tools you can invoke through MCP-compatible interfaces. Use the fetch_url_content tool to retrieve and process content from a URL, and use the web_search tool to perform semantic web searches and obtain relevant results.
- To fetch content, provide the target URL to fetch_url_content and receive the retrieved page content as the response. This is useful for quickly grabbing article text, metadata, or content for summarization.
- To search the web, call web_search with a query. The tool uses Jina AI’s crawling and semantic understanding to return relevant results and summaries that you can present to the user.
Prerequisites you need on your machine before installing the MCP server:
Choose an installation path that matches your environment and follow the steps below.
Option A: Claude Desktop Integration (easiest) lets you install and use the server directly from Claude Desktop.
# Clone the project repository
git clone https://github.com/hypersniper05/JinaWebSearchMCP.git
cd JinaWebSearchMCP
# Set your API key (Linux/Mac)
export JINA_API_KEY=your_actual_api_key_here
# Windows
#set JINA_API_KEY=your_actual_api_key_here
# Install dependencies and integrate with Claude Desktop
pip install -r requirements.txt
mcp install server.py --name "Jina Web Search"Option B: Development and testing with MCP Inspector.
# Install development dependencies
uv add mcp[cli] requests
# Test with MCP development tools
uv run mcp dev server.py
# Or use pip-based flow
pip install -r requirements.txt
mcp dev server.pyOption C: Docker (production-ready) deployment.
# Clone the project repository
git clone https://github.com/hypersniper05/JinaWebSearchMCP.git
cd JinaWebSearchMCP
# Set API key
cp .env.example .env
# Edit .env and set JINA_API_KEY
# Build and run with Docker Compose
docker-compose up -d
# Check logs
docker-compose logs -f
# Stop the server
docker-compose downOption D: Direct execution (no MCP tooling) if you prefer running the server directly.
pip install -r requirements.txt
# Set the API key
export JINA_API_KEY=your_api_key_here
# Run the server directly
python server.pyKey runtime configuration is focused on the API key and network binding. The server is designed to listen on all interfaces for Docker compatibility and exposes the MCP API over a streamable HTTP transport on port 5003.
Environment variable for authentication and access control: set JINA_API_KEY with your Jina AI API key.
Server details:
HTTP MCP endpoint for client connections (example): http://localhost:5003/mcp. Use this URL in MCP clients that connect over HTTP to reach the server.
The server relies on a Jina AI API key for access to the underlying content fetching and search capabilities. Keep your API key secure and do not expose it in public environments. Logs are available to help you monitor activity and diagnose issues.
Docker-based deployment includes multi-stage builds, health checks, and automatic restart policies to ensure production readiness. Use the provided docker-compose setup to manage the server lifecycle and verify operation with container logs.
- Ensure your API key is correctly set in the environment before starting the server. - If the server fails to start, check Docker logs or the terminal output for missing dependencies or misconfigured environment variables. - When using Claude Desktop, install the server with the MCP workflow to expose the available tools automatically in the UI. - If you switch between deployment methods (Docker, local Python, or Claude Desktop), re-check that the port 5003 is accessible and that the MCP transport is properly configured.
The server provides two core tools to interact with the web: fetch_url_content to retrieve URL content and web_search to perform semantic searches. Tools are exposed through MCP and can be accessed by any MCP-compatible client, including Claude Desktop and VS Code MCP extensions.
Fetches and returns content from a given URL using Jina AI's crawler service.
Performs a semantic web search using the Jina AI API and returns relevant results.