Gasoline + Claude Code
Gasoline is an open-source MCP server that gives Claude Code real-time access to browser console logs, network errors, exceptions, WebSocket events, and live DOM state. Zero dependencies.
Project-Level Config (Recommended)
Section titled “Project-Level Config (Recommended)”Create .mcp.json in your project root:
{ "mcpServers": { "gasoline": { "command": "npx", "args": ["gasoline-mcp"] } }}Gasoline only fires up when you’re in this project.
Global Config
Section titled “Global Config”Available in all projects — add to ~/.claude/settings.json:
{ "mcpServers": { "gasoline": { "command": "npx", "args": ["gasoline-mcp"] } }}Once configured, Claude Code auto-ignites the server. Ask:
- “What browser errors do you see?”
- “Check the network responses for /api/users”
- “Run an accessibility audit on this page”
- “What’s the DOM structure of the nav?”
- “Any WebSocket connection issues?”
Claude uses the right MCP tool and returns actionable debugging info.
Troubleshooting
Section titled “Troubleshooting”- Restart Claude Code after adding config
- Check extension popup — should show “Connected”
- Verify tools: Ask “What MCP tools do you have?”
- Check logs: Look for MCP connection errors in output