MCP Local File Reader
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@MCP Local File Readerread the contents of my notes.txt file"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
MCP Local File Reader
一个基于 Model Context Protocol (MCP) 的本地文件读取服务器,允许 AI 模型安全地访问本地文件系统。
功能特点
资源 (Resources)
列出和访问本地文件系统中的文件
支持多种文件类型,包括文本文件和二进制文件
自动检测文件 MIME 类型,提供适当的内容处理
工具 (Tools)
read_file- 读取指定文件的内容对文本文件返回完整内容
对二进制文件返回文件信息摘要
list_files- 列出指定目录中的所有文件返回文件名列表
get_file_info- 获取指定文件的详细信息返回文件大小、类型、创建时间等元数据
Related MCP server: Filesystem MCP Server
安装
npm install mcp-local-file-reader使用方法
作为命令行工具
安装后,可以直接在命令行中运行:
npx mcp-local-file-reader此时会启动一个 MCP node服务器,监听llm对话。
与 AI 工具集成
在 Windsurf 中使用
在windsurf中,不需要手动启动mcp-local-file-reader,只需要配置即可,windsurf会自动启动mcp-local-file-reader(在windsurf的mcp_config.json中配置,点击refresh刷新服务器)。
在 Windsurf 的 mcp_config.json 配置文件中添加以下配置(FILE_TOOLS_API_KEY暂时还不需要):
本地化部署
{
"servers": {
"file-tools": {
"command": "cmd",
"args": [
"/c",
"node",
"path/to/mcp-local-file-reader/build/index.js"
],
"env": {
"FILE_TOOLS_API_KEY": ""
}
}
}
}使用npm的形式部署
{
"servers": {
"file-tools": {
"command": "cmd",
"args": [
"/c",
"npx",
"mcp-local-file-reader"
],
"env": {
"FILE_TOOLS_API_KEY": ""
}
}
}
}点击windsurf对话框的小锤子图标,点击refrsh刷新服务器 官方配置说明:https://docs.codeium.com/windsurf/mcp
重启 Windsurf 以加载新的 MCP 配置
在其他 MCP 兼容的 AI 应用中使用
按照特定应用的 MCP 集成指南,添加此服务器作为工具提供者。cursor配置与windsurf中的配置类似,vscode的cline会稍微复杂一些。但是本质都是配置mcp.json,可以类似的配置。
开发
安装依赖:
npm install构建服务器:
npm run build开发模式(自动重新构建):
npm run watch使用 MCP Inspector 测试:
npm run inspector安全注意事项
此服务器允许 AI 模型访问本地文件系统,请谨慎使用并确保:
只允许访问必要的目录
不要暴露敏感文件或目录
在生产环境中使用前,考虑添加额外的安全限制
许可证
MIT
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- AlicenseAqualityCmaintenanceA Model Context Protocol server that provides secure and intelligent interaction with files and filesystems, offering smart context management and token-efficient operations for working with large files and complex directory structures.Last updated2166MIT
- Flicense-qualityFmaintenanceA Model Context Protocol server that extends AI capabilities by providing file system access and management functionalities to Claude or other AI assistants.Last updated2215
- AlicenseAqualityFmaintenanceA secure Model Context Protocol server that provides controlled filesystem access within predefined directories, enabling AI models to perform file and directory operations with strict path validation.Last updated16447MIT
- AlicenseAqualityFmaintenanceA Model Context Protocol server that provides AI agents with secure access to local filesystem operations, enabling reading, writing, and managing files through a standardized interface.Last updated103142Apache 2.0
Related MCP Connectors
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
A Model Context Protocol server for Wix AI tools
MCP (Model Context Protocol) server for Appwrite
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
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/sworddut/mcp-local-file-reader'
If you have feedback or need assistance with the MCP directory API, please join our Discord server