Reducing MCP token usage by replacing servers with CLI alternatives

Token optimization through MCP server reduction
A developer discovered that each MCP server added to their setup was dumping its entire tool schema into the context window with every message, consuming 30-40% of their available context. This was causing them to hit context limits faster than expected.
Specific MCP-to-CLI replacements
After auditing their setup, they identified several MCP servers that had CLI equivalents and made these replacements:
agentmail mcp → agentmail cli(installed vianpm install -g agentmail-cli) - allows Claude to manage inbox, send emails, and check messages through bashgithub mcp → gh cli- using commands likegh issue createandgh pr listpostgres mcp → psql- using commands likepsql -c "select * from users"
MCP servers kept in the setup
Two MCP servers were retained because they lacked good CLI alternatives:
- playwright mcp - for browser automation tasks
- memory mcp - for persistent memory functionality
Resulting configuration and rule
The developer reduced their MCP server count from 6 to 2 while maintaining all previous functionality. They established a new rule: "if there's a CLI, skip the MCP. Only add MCPs for stuff that genuinely doesn't have a command line option." This change made their context window feel larger and reduced how often they hit limits.
📖 Read the full source: r/ClaudeAI
👀 See Also

Silent Success: One Dev's Approach to Cron Job Alerting
A developer on r/openclaw stops sending success notifications for healthy cron runs, alerting only on auth failures, state corruption, or repeated failures.

Two Small Prompt Changes Cut Claude Editing Time by 80%
Put role instruction at the start and format instruction at the end. One user reports cutting editing iterations from three to one.

AI Agents Exposed My Sloppy Prompts: Clarity Beats Smarter Models
A Reddit post reveals that AI agents don't magically fix unclear tasks — they just make the feedback immediate. The real problem was the user's own lack of clarity.

Building with Codex, Executing with OpenClaw: A Practical Split That Works
A developer shares how they broke through OpenClaw frustration by building automation logic with Codex and using OpenClaw purely as the execution layer — plus how Apple Messages via CarPlay made it feel closer to a Jarvis-like assistant.