dimitar-grigorov/mcp-file-tools
by Various
MCP server for file operations on non-UTF-8 text: detects the encoding from the bytes, hands the model UTF-8, and writes back in the original encoding with BOM and CRLF/LF intact.
MCP
dimitar-grigorov/mcp-file-tools
Added 3 Sept 2026
Overview
MCP server for file operations on non-UTF-8 text. Detects the encoding from bytes, converts to UTF-8 for the model, and writes back in the original encoding with BOM and CRLF/LF intact. Supports 24 encodings including Cyrillic, Western European, KOI8, ISO-8859, UTF-16, and GBK.
Best for
Best for
Developers working with legacy encoded text files in MCP-based workflows
Use cases
- Reading legacy files with CP1251 or KOI8 encodings
- Editing files without corrupting original encoding and line endings
- Processing GBK or UTF-16 documents through an MCP client
How to use
Install
npx @modelcontextprotocol/inspector go run ./cmd/mcp-file-tools -- /path/to/allowed/dir Tools exposed
MCP_DEFAULT_ENCODINGMCP_DEFAULT_LINE_ENDINGSMCP_MEMORY_THRESHOLDMCP_DETECTION_CANDIDATESMCP_FILE_TOOLS_ALLOWED_DIRSMCP_FILE_TOOLS_NO_CWD_FALLBACK
Tested with
Claude Desktop, Claude Code, Cursor, VS Code, ChatGPT
Notes
MCP server for file operations on non-UTF-8 text. Detects the encoding from bytes, converts to UTF-8 for the model, and writes back in the original encoding with BOM and CRLF/LF intact. Supports 24 encodings including Cyrillic, Western European, KOI8, ISO-8859, UTF-16, and GBK.
22 stars on GitHub. Last updated 2026-09-02. Licensed GPL-3.0.
Use cases
- Reading legacy files with CP1251 or KOI8 encodings
- Editing files without corrupting original encoding and line endings
- Processing GBK or UTF-16 documents through an MCP client
Pros
- Preserves original encoding, BOM, and CRLF/LF
- Supports a wide range of legacy encodings
- Simple Go implementation, easy to deploy
Cons
- Limited to file operations, not a general-purpose tool
- Small community (22 stars), may lack extensive testing
- Requires MCP client integration
Indexed from awesome-mcp-servers-punkpeye and enriched against its public facts.
Pros
- Preserves original encoding, BOM, and CRLF/LF
- Supports a wide range of legacy encodings
- Simple Go implementation, easy to deploy
Cons
- Limited to file operations, not a general-purpose tool
- Small community (22 stars), may lack extensive testing
- Requires MCP client integration
Pairs with
Other entries in the index that connect to this one. Click through to see the chain.
Get the free Developer’s Field Guide
A 27-page field guide to the AI coding workflow with Claude. Claude Code, MCP servers, the prompt patterns that work, and what to delegate. Free.
Enter your work email. We send it straight over, plus a few short notes worth knowing. Unsubscribe any time.
