MCP Local File Reader

Provides file system operations and multi-format document support via MCP.
  • typescript

0

GitHub Stars

typescript

Language

5 months ago

First Indexed

2 months ago

Catalog Refreshed

Documentation & install

Readme and setup notes from the catalogue, plus a client-ready config you can copy for your MCP host.

Installation

Add the following to your MCP client configuration file.

Configuration

View docs
{
  "mcpServers": {
    "yryuu-mcp-localfile-all-read": {
      "command": "npx",
      "args": [
        "-y",
        "github:yryuu/mcp-localfile-all-read"
      ],
      "env": {
        "MCP_ROOT_PATH": "YOUR_ROOT_PATH"
      }
    }
  }
}

You can run a local MCP server that reads and processes files across multiple formats, from simple text to complex documents like PDFs, Excel, Word, and presentations. It exposes a set of practical file operations you can invoke from any MCP-compatible client to list directories, read files, search content, and extract per-sheet data, all while safely restricting access to a designated root directory.

How to use

You interact with the Local File MCP Server through an MCP client by configuring it as a server endpoint. Use the provided commands to run the server locally or connect to it over an HTTP/MCP bridge if available. Once connected, you can perform core actions such as listing directory contents, reading file contents (with automatic format detection), retrieving file metadata, searching for text patterns across files, and extracting data from multi-format documents.

How to install

Prerequisites: you need Node.js and npm installed on your machine to run the MCP server locally.

Option 1: Using npx (recommended) to run directly without global installation.

{
  "mcpServers": {
    "localfile": {
      "command": "npx",
      "args": [
        "-y",
        "github:yryuu/mcp-localfile-all-read"
      ],
      "env": {
        "MCP_ROOT_PATH": "/path/to/your/directory"
      }
    }
  }
}

Option 2: Local installation if you prefer a direct run from a package.

npx github:yryuu/mcp-localfile-all-read

Configuration and environment

Configure the MCP client to point to the local server and set the root directory you want to access. The server is designed to validate paths so users cannot escape the designated root.

{
  "mcpServers": {
    "localfile": {
      "command": "npx",
      "args": ["-y", "github:yryuu/mcp-localfile-all-read"],
      "env": {
        "MCP_ROOT_PATH": "/Users/yourname/Documents"
      }
    }
  }
}

Security and encoding considerations

The server enforces path validation to prevent access outside the configured root directory and automatically detects and handles character encodings for text-based files, including Shift-JIS and UTF-8.

Usage notes and examples

You can perform practical tasks such as listing a directory, reading a file, detecting formats, and extracting multi-sheet data from Excel workbooks. Common actions include:

  • List contents of a directory
  • Read the contents of a file such as a PDF or Excel workbook
  • Get file metadata
  • Search for text patterns across files
  • List all sheets in an Excel file and read a specific sheet

Available tools

list_directory

List contents of a directory given a relative path from the root. Use "." to refer to the root.

read_file

Read file content with automatic format detection for text, PDF, Excel, Word, PowerPoint, and CSV formats.

get_file_info

Retrieve metadata about a file or directory, including size, type, and timestamps.

search_content

Search for text patterns within files, with optional case sensitivity and file name filtering.

find_files

Find files by name pattern or regex within a given path.

list_excel_sheets

List all sheet names in an Excel file.

read_excel_sheet

Read a specific sheet from an Excel file and return data as JSON.

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational