Folder MCP
About
A server for local folder operations and file system access.
Details
- Author
- okets
- Categories
- File Management, Other, Productivity
Jump to
Setup
Install Folder MCP in your MCP client (Claude Desktop, Cursor, Windsurf, and others).
Repository: https://github.com/okets/folder-mcp
Follow the installation instructions in the repository README, then restart your MCP client.
folder-mcp (Under Development, will be released soon enough)
Model Context Protocol Server for Folder Operations
A Model Context Protocol (MCP) server that provides tools for reading and analyzing folder structures, enabling LLMs to interact with local file systems safely and efficiently.
folder-mcp was created for a simple but powerful purpose: take your local folder and make it accessible to Large Language Models (LLMs) running anywhere. You don't need to upload your files to the cloud or use a third-party service.
it creates RAG (Retrieval-Augmented Generation) capabilities for your local files, allowing LLMs to read, search, and analyze documents in a secure and structured way. This server implements the Model Context Protocol (MCP) standard, allowing LLMs to interact with local file systems through a set of defined tools. This project is designed to work with MCP clients like Claude Desktop, Cursor, VsCode and others, providing a secure and efficient way to access and manipulate files within specified folders.
- Read files from specified folders with path validation
- Security checks to prevent directory traversal attacks
- Support for various file types and encodings
- List all files in a folder recursively
- Search files by name patterns (glob support)
- Get folder information and metadata
- Exclude common directories like node_modules and .git
- Standard Model Context Protocol server implementation
- Works with Claude Desktop and other MCP clients
- Stdio transport for seamless integration
- Structured tool definitions with JSON schemas
- TypeScript implementation with full type safety
- Clear error handling and informative responses
- Simple CLI interface for testing and development
git clone https://github.com/okets/folder-mcp.git cd folder-mcp npm install npm run build
folder-mcp uses a centralized configuration system stored inconfig.yamlat the project root. This YAML file contains settings for embeddings, caching, processing, API, logging, and development configurations.
The system supports multiple embedding models with GPU acceleration via Ollama:
# Embedding Model Configuration embeddings: defaultModel: "nomic-v1.5" ollamaApiUrl: "http://127.0.0.1:11434" batchSize: 32 timeoutMs: 30000 models: # Model definitions with dimensions, descriptions, etc. # Cache Configuration cache: defaultCacheDir: "~/.cache/folder-mcp" maxCacheSize: "10GB" cleanupIntervalHours: 24 # Text Processing Configuration processing: defaultChunkSize: 1000 defaultOverlap: 200 maxConcurrentOperations: 10 # Development & Logging options logging: level: "info" format: "json" development: enableDebugOutput: false mockOllamaApi: false
For detailed configuration options, seeCONFIGURATION.md.
πVersion 1.0- Basic MCP Server (13/30 planned features complete)
This is the foundation release providing secure file system access through MCP. The full vision includes semantic search, embeddings, and intelligent document parsing - seeROADMAP.mdfor the complete development plan.
- β
Basic file reading and folder operations
- β
Security validation and path protection
- β
Pattern-based file searching
- β
MCP protocol integration
Coming next:Smart text chunking, semantic embeddings, vector search (see all 30 planned features)
This server is designed to be used with MCP clients like Claude Desktop. Add it to your Claude Desktop configuration:
{ "mcpServers": { "folder-mcp": { "command": "node", "args": [ "C:\\Path\\To\\folder-mcp\\dist\\mcp-server.js", "C:\\Path\\To\\folder-mcp" ], "env": {} } } }
β οΈCritical Claude Desktop Integration Note: The MCP protocol requires that ONLY valid JSON-RPC messages go to stdout. Any logging or debugging output to stdout will break the connection. All logs should be redirected to stderr only. See CLAUDE_DESKTOP_SETUP.md for detailed troubleshooting tips.
The server currently provides the following tools:
- get_status- A system status tool that returns processing information to verify connection
- Optional parameter:name- A name to include in the greeting
Read the contents of a specific file within a folder.
- folder_path: Path to the folder containing the file
- file_path: Relative path to the file within the folder
Search for files matching a specific pattern.
- folder_path: Path to the folder to search
- pattern: File pattern (e.g., ".md", ".txt", "config.")
- folder_path: Path to the folder to list
Get information about a folder including file count and metadata.
- folder_path: Path to the folder to analyze
- Path Validation: Prevents access to files outside the specified folder
- Directory Exclusions: Automatically excludes node_modules, .git, and cache folders
- Error Handling: Graceful handling of permission errors and invalid paths
The server implements the Model Context Protocol standard with the following components:
π‘ MCP Client (Claude Desktop) β π Stdio Transport β π₯οΈ MCP Server β π File System
1. Client Request β 2. Tool Validation β 3. Path Security Check β 4. File Operation β 5. Response
- Tool Handlers: Process read_file, search_files, list_files, and get_folder_info requests
- Security Layer: Validates paths and prevents directory traversal
- File Operations: Uses Node.js fs and glob for efficient file system access
- Transport Layer: Stdio transport for communication with MCP clients
- @modelcontextprotocol/sdk: MCP protocol implementation
- glob: Pattern-based file searching
- typescript: Type-safe development
- Additional libraries for future file parsing capabilities
The server uses glob patterns for file searching:
- - All files
- .md- Markdown files only
- /.js- JavaScript files recursively
- config.- Any file starting with "config"
Automatically excluded from all operations:
- /node_modules/
- /.git/
- /.folder-mcp/
The server can be tested with any MCP-compatible client. For Claude Desktop, add the configuration to your settings file.
π Development Roadmap:SeeROADMAP.mdfor visual progress andGITHUB_ISSUES.mdfor detailed task breakdown.
- Phase 3:Smart text chunking and semantic embeddings
- Phase 4:FAISS vector search and similarity matching
- Phase 5:Enhanced MCP integration with semantic search
- Phase 6:Real-time file watching and configuration system
- Phase 7:Performance optimization and comprehensive testing
- Phase 8:Documentation and npm release
Transform any folder into an intelligent knowledge base with:
- Multi-format parsing: PDF, Word, Excel, PowerPoint with structure preservation
- Semantic embeddings: Nomic Embed model for intelligent content understanding
- Vector search: FAISS-powered similarity search for context-aware retrieval
- Smart chunking: Meaning-based content segmentation
- Real-time updates: File watching with automatic re-indexing
- RAG capabilities: Enable LLMs to query folder contents intelligently
- Fork the repository
- Create a feature branch (git checkout -b feature/amazing-feature)
- Commit your changes (git commit -m 'Add amazing feature')
- Push to the branch (git push origin feature/amazing-feature)
- Open a Pull Request
MIT License - seeLICENSEfile for details.
- Built with the Model Context Protocol SDK
- Uses TypeScript for type safety and developer experience
- Designed for secure and efficient file system access
- Compatible with Claude Desktop and other MCP clients
Enable your LLM to work with local folders through the Model Context Protocol!*π
A cross-platform filesystem server for Linux, macOS, and Windows with secure path restrictions.
Organize files in your Downloads folder using Cursor IDE with customizable rules.
Visualize directory structures with real-time updates, configurable depth, and smart exclusions for efficient project navigation.
A universal file download assistant supporting secure and batch processing of any file type.
Fast local full-text search for Windows files β names, contents, and OCR'd screenshot text; read-only MCP tools.
The fastest and the most accurate file search toolkit for AI agents
A server for programmatic exploration of local files and folders.
A server providing comprehensive file system operations, automatically downloaded and built on first use.
A simple utility to combine multiple files into a single file.
A server for performing filesystem operations such as reading/writing files, managing directories, and searching.
Sign in to leave a review
Use Google, GitHub, or an email account so ratings stay tied to real people.
No reviews posted yet.




