MCP JSON Navigator
A Model Context Protocol (MCP) server that provides intelligent JSON navigation and search capabilities for AI assistants. Mostly design for saving tokens and manipulating large files > 10MB in a few seconds.
Require FileSystem. Note the json should note use "." in keys
Capabilities
"Search keys & values ("phone", "email", "location")"
"Precise path lookup with optional case-sensitive matching"
"Structural exploration of very large JSON files (without loading everything into model context)"
π¦ Installation
MacOS/Linux
Windows (tested)
βοΈ Configuration
Add to your MCP settings file (e.g., claude_desktop_config.json):
Replace YOUR_USERNAME and the path with your actual installation location.
π Json-query
π€οΈ Json-explore
π― Who is this for?
This tool is designed for AI assistants that need to navigate and search through large JSON files efficiently.
When dealing with massive JSON structures (hundreds of MB, deeply nested objects, thousands of entries), AI models face several challenges:
Token limitations: Large JSON files can't fit entirely in the context window
Performance: Parsing and searching large structures is slow
Precision: Finding specific data in complex nested structures is difficult
MCP JSON Navigator solves these problems by:
Providing intelligent exploration with adjustable verbosity levels
Using fuzzy search with camelCase tokenization for natural queries
Allowing precise navigation using JSON paths
Grouping and scoring results intelligently
β¨ Features
1. Smart JSON Exploration (json-explore)
Navigate through JSON structures with adjustable detail levels:
Parameters:
filepath: Path to the JSON filejsonpath(optional): Navigate to specific path (e.g.,users[0].profile)verbosity: 0-5 (default: 4)0: Keys only1: Keys with types2: Keys with counts3: Keys with counts and character sizes4: Smart expansion for small objects5: Raw data
listDisplayLimit: Max items to show in arrays (default: 5)objectDisplayLimit: Max keys to show in objects (default: 6)charDisplayLimit: Max characters for expansion (default: 200)
2. Intelligent Search (json-query)
Search through keys and values with fuzzy matching and camelCase tokenization:
How it works:
Tokenization: Splits camelCase, snake_case, kebab-case, and generates n-grams
Fuzzy Matching: Uses similarity scoring to find partial matches
Weighted Scoring: Keys score higher than values
Smart Grouping: Groups related results from the same JSON branch
Parameters:
filepath: Path to the JSON filequery: Search term (supports partial matches)limit: Max results to return (default: 20, min: 10)caseSensitive: Enable exact matching filter (default: false)
When caseSensitive: true, returns an additional exactMatch field with results that contain the exact query string.
π Usage Examples
Example 1: Exploring a Large JSON File
Example 2: Searching for Contacts
Example 3: Complex Navigation
π οΈ Technical Details
Architecture
TypeScript-based: Fully typed for reliability
MCP Protocol: Built on Model Context Protocol standard
Fast Fuzzy Search: Uses
fast-fuzzylibrary for efficient matchingInverted Index: Builds searchable index with n-gram tokenization
Smart Grouping: Groups results by JSON structure for better relevance
Search Algorithm
Tokenization:
Normalizes text (camelCase β camel Case)
Generates 3-5 character n-grams
Builds inverted index: token β [paths with weights]
Query Phase:
Tokenizes query
Computes fuzzy similarity scores
Accumulates scores per path
Applies key/value weights
Result Grouping:
Groups paths by structural similarity
Scores by frequency Γ depth
Returns top representative paths
π License
MIT License - See LICENSE file for details.
You are free to:
β Use commercially
β Modify
β Distribute
β Use privately
Just mention the source: https://github.com/Adsdworld/mcp-json-navigator
π€ Contributing
Contributions are welcome! Please feel free to submit issues or pull requests.
π Related Projects
π Links
GitHub: https://github.com/Adsdworld/mcp-json-navigator
MCP Documentation: https://modelcontextprotocol.io/
Built with β€οΈ for AI assistants navigating complex JSON structures.