EasyOCR MCP Server

EasyOCR MCP Server

An MCP server that provides OCR capabilities using the EasyOCR library, supporting over 80 languages and GPU acceleration. It enables processing images from base64 strings, local files, or URLs with options for text-only or detailed coordinate and confidence output.

Category
Visit Server

README

EasyOCR MCP Server

A Model Context Protocol (MCP) server that provides OCR capabilities using the EasyOCR library.

About EasyOCR:
EasyOCR is an open-source Optical Character Recognition (OCR) library developed by JaidedAI. It supports over 80 languages, offers GPU acceleration, and is known for its ease of use and high accuracy. EasyOCR can extract text from images, scanned documents, and photos, making it suitable for a wide range of OCR tasks. For more details, visit the EasyOCR GitHub repository.

Features

  • 3 OCR Tools: Process images from base64, files, or URLs
  • Multi-language Support: Support for 80+ languages with dynamic selection
  • Flexible Output: Choose between text-only or detailed results with coordinates and confidence
  • Performance Optimized: Reader caching for better performance
  • Native EasyOCR Output: Returns EasyOCR's original format

Installation

# Install PyTorch with GPU support. Skip this step if you plan to use CPU only.
# For GPU support, adjust the command based on your system. For details, see: https://pytorch.org/get-started/locally/
uv pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu128

# Install all dependencies
uv sync

# Run tests to verify the implementation
uv run test.py
uv run test-gpu.py

Usage

Available Tools

  1. ocr_image_base64 - Process base64 encoded images
  2. ocr_image_file - Process image files from disk
  3. ocr_image_url - Process images from URLs

Parameters

  • detail: Output detail level (default: 1)
    • 0: Text only - ['text1', 'text2', ...]
    • 1: Full details - [([[x1,y1], [x2,y2], [x3,y3], [x4,y4]], 'text', confidence), ...]
  • paragraph: Enable paragraph detection (default: false)
  • width_ths: Text width threshold for merging (default: 0.7)
  • height_ths: Text height threshold for merging (default: 0.7)

Note: Language selection is configured via the EASYOCR_LANGUAGES environment variable in your MCP configuration (see Configuration section below).

Example Output

Detail Level 1 (Full Details):

[
    ([[189, 75], [469, 75], [469, 165], [189, 165]], '愚园路', 0.3754989504814148),
    ([[86, 80], [134, 80], [134, 128], [86, 128]], '西', 0.40452659130096436)
]

Detail Level 0 (Text Only):

['愚园路', '西', '东', '315', '309', 'Yuyuan Rd.', 'W', 'E']

Running the Server

# Run the MCP server
uv run easyocr-mcp.py

# Or use mcp command
mcp run easyocr-mcp.py

MCP Configuration Example

If you are running this as a server for a parent MCP application, you can configure it in your main MCP config.json.

Windows Example:

{
  "mcpServers": {
    "easyocr-mcp": {
      "command": "uv",
      "args": [
        "--directory",
        "X:\\path\\to\\your\\project\\easyocr-mcp",
        "run",
        "easyocr-mcp.py"
      ],
      "env": {
        "EASYOCR_LANGUAGES": "en,ch_tra,ja"
      }
    }
  }
}

Linux/macOS Example:

{
  "mcpServers": {
    "easyocr-mcp": {
      "command": "uv",
      "args": [
        "--directory",
        "/path/to/your/project/easyocr-mcp",
        "run",
        "easyocr-mcp.py"
      ],
      "env": {
        "EASYOCR_LANGUAGES": "en,ch_tra,ja"
      }
    }
  }
}

Environment Variables

  • EASYOCR_LANGUAGES: Comma-separated list of language codes (default: en)
    • Examples: en, en,ch_sim, ja,ko,en

Supported Languages

EasyOCR supports 80+ languages including:

  • en - English
  • ch_sim - Chinese Simplified
  • ch_tra - Chinese Traditional
  • ja - Japanese
  • ko - Korean
  • fr - French
  • de - German
  • es - Spanish
  • And many more...

GPU/CPU Configuration

GPU usage is determined at installation time based on your PyTorch installation. No runtime configuration needed.

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
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
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
Qdrant Server

Qdrant Server

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

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
E2B

E2B

Using MCP to run code via e2b.

Official
Featured