Skip to main content
Glama

tavily-mcp-python

by MertAtesmen

Tavily MCP Server

Tavily MCP Server implementation that uses fastmcp and supports both sse and stdio transports. To use this server, you need a Tavily account and a Tavily API key, which must be loaded into the TAVILY_API_KEY environment variable.

The Tavily MCP server provides:

  • search, extract, map, crawl tools
  • Real-time web search capabilities through the tavily-search tool
  • Intelligent data extraction from web pages via the tavily-extract tool
  • Powerful web mapping tool that creates a structured map of website
  • Web crawler that systematically explores websites

Prerequisites

  • git installed. (To clone the repo)
  • uv installed.
  • docker installed (Optional: If you are planning to use the SSE server inside a docker container).

To install uv in Linux and MacOS type this in your terminal:

curl -LsSf https://astral.sh/uv/install.sh | sh

Environment Variables

Copy the .env.example file and rename that to .env. Then paste your TAVILY_API_KEY inside there

TAVILY_API_KEY=<YOUR-API-KEY>

Optional: You can also configure the port if you are planning to use SSE.

TAVILY_MCP_PORT=<PORT>

Running the SSE server

While inside the repo run:

uv run --env-file .env tavily-mcp-sse

Running on STDIO

{ "mcpServers": { "tavily-mcp-server": { "command": "uv", "args": [ "run", "--directory", "<LOCATION-TO-THE-REPO>", "tavily-mcp-stdio" ], "env": { "TAVILY_API_KEY": "<YOUR-API-KEY>" } } } }

Docker SSE Server

First you need to build the image using the Dockerfile inside this repository. Run this to build the image:

docker build -t tavily-mcp .

Then you can run the container using the environment variables inside the env file

docker run --name tavily-mcp \ -p 127.0.0.1:8000:8000 \ --env-file .env \ tavily-mcp

Or you can specify the environment variables yourself.

docker run --name tavily-mcp \ -p 127.0.0.1:8000:8000 \ -e TAVILY_API_KEY=<YOUR-API-KEY> tavily-mcp
Install Server
A
security – no known vulnerabilities
F
license - not found
A
quality - confirmed to work

remote-capable server

The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.

Tavily MCP Server implementation that uses fastmcp and supports both sse and stdio transports. It also supports more up to date functionalities of Tavily.

  1. Prerequisites
    1. Environment Variables
      1. Running the SSE server
        1. Running on STDIO
          1. Docker SSE Server

            Related MCP Servers

            • -
              security
              A
              license
              -
              quality
              This MCP server performs multi-topic searches in business, news, finance, and politics using the Tavily API, providing high-quality sources and intelligent summaries.
              Last updated -
              1
              1
              Python
              MIT License
              • Apple
              • Linux
            • A
              security
              A
              license
              A
              quality
              An MCP server implementation that integrates the Tavily Search API, providing optimized search capabilities for LLMs.
              Last updated -
              1
              TypeScript
              MIT License
              • Apple
            • A
              security
              F
              license
              A
              quality
              An MCP protocol server that enables web search functionality using the Tavily API, allowing AI assistants to perform internet searches in real-time.
              Last updated -
              4
              2
              Python
            • -
              security
              A
              license
              -
              quality
              MCP server for using various search tools like Tavily API. Planning to support various search tools (i.e. wiki search, searxng, etc)
              Last updated -
              1
              Python
              MIT License
              • Apple
              • Linux

            View all related MCP servers

            MCP directory API

            We provide all the information about MCP servers via our MCP API.

            curl -X GET 'https://glama.ai/api/mcp/v1/servers/MertAtesmen/tavily-mcp-python'

            If you have feedback or need assistance with the MCP directory API, please join our Discord server