Searchfox MCP Server

Searchfox MCP Server

Provides access to Mozilla's Searchfox code search service, enabling AI assistants to search through Mozilla's codebases and retrieve file contents from repositories like mozilla-central, autoland, and ESR branches.

Category
Visit Server

README

Searchfox MCP Server

A Model Context Protocol (MCP) server that provides access to Mozilla's Searchfox code search service. This server enables AI assistants to search through Mozilla's codebases and retrieve file contents directly.

Features

  • Code Search: Search across Mozilla repositories using Searchfox's powerful indexing
  • File Retrieval: Get file contents from Mozilla repositories via GitHub raw content API
  • Multiple Repositories: Support for mozilla-central, autoland, mozilla-beta, ESR branches, and comm-central
  • Flexible Search Options: Case sensitivity, regular expressions, and path filtering

Available Tools

search_code

Search for code patterns across Mozilla repositories using Searchfox.

Parameters:

  • query (string): Search query using exact literal string matching (no OR logic, no phrase matching)
  • repo (string, optional): Repository to search in (defaults to "mozilla-central")
  • path (string, optional): Filter results by file path using glob patterns with ^ and $ operators
  • case (boolean, optional): Enable case sensitive search (default: false)
  • regexp (boolean, optional): Treat query as regular expression pattern (default: false)
  • limit (number, optional): Maximum number of results (default: 50)

Important Search Notes:

  • Uses exact string matching only - multiple words are treated as a single literal string
  • No search operators, OR logic, or phrase matching with quotes
  • For broader searches, use separate queries or enable regexp mode

Supported Repositories:

  • mozilla-central (default) → GitHub main branch
  • autoland → GitHub autoland branch
  • mozilla-beta → GitHub beta branch
  • mozilla-release → GitHub release branch
  • mozilla-esr115, mozilla-esr128, mozilla-esr140 → Corresponding ESR branches
  • comm-central → GitHub mozilla/releases-comm-central main branch

get_file

Retrieve the contents of a specific file from a Mozilla repository. Files are retrieved from GitHub raw content API (https://raw.githubusercontent.com/)

Parameters:

  • path (string): File path within the repository
  • repo (string, optional): Repository name (defaults to "mozilla-central")

Usage

First clone the repository and run:

# Install dependencies and build the project
npm install
npm run build

Then add the MCP server to your client.

Claude Desktop Configuration

Your claude_desktop_config.json file should look like this:

{
  "mcpServers": {
    "searchfox": {
      "command": "node",
      "args": [
        "/path/to/searchfox-mcp/dist/index.js"
      ]
    },
  }
}

Development

# Install dependencies
npm install

# Build the project
npm run build

# Run in development mode with hot reload
npm run dev

# Type checking without emitting files
npm run tsc

# Run linting
npm run lint

# Fix linting issues automatically
npm run lint:fix

# Format code
npm run format

# Check formatting
npm run format:check

Configuration

The server runs via stdio transport and communicates using the MCP protocol. Configure your MCP client to connect to this server using the built executable.

Recommended Servers

playwright-mcp

playwright-mcp

A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.

Official
Featured
TypeScript
Magic Component Platform (MCP)

Magic Component Platform (MCP)

An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.

Official
Featured
Local
TypeScript
Audiense Insights MCP Server

Audiense Insights MCP Server

Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.

Official
Featured
Local
TypeScript
VeyraX MCP

VeyraX MCP

Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.

Official
Featured
Local
graphlit-mcp-server

graphlit-mcp-server

The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.

Official
Featured
TypeScript
Kagi MCP Server

Kagi MCP Server

An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.

Official
Featured
Python
E2B

E2B

Using MCP to run code via e2b.

Official
Featured
Neon Database

Neon Database

MCP server for interacting with Neon Management API and databases

Official
Featured
Exa Search

Exa Search

A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.

Official
Featured
Qdrant Server

Qdrant Server

This repository is an example of how to create a MCP server for Qdrant, a vector search engine.

Official
Featured