eval
Execute custom JavaScript code
How to use it
eval is exposed by the Electron MCP Server MCP server. Add the server to your MCP client (Claude Desktop, Cursor, Windsurf and others), and the eval tool becomes available to the model automatically. See the full listing for setup details and every tool this server provides.
Install Electron MCP Server
npx -y electron-mcp-serverOther tools in Electron MCP Server (17)
Build Electron applications for distribution.
Click buttons by CSS selector (basic method)
Click elements by their visible text, aria-label, or title (more reliable than selectors)
Gracefully close the Electron application.
Send console messages
Fill input fields by selector, placeholder text, or associated label text
Analyze all interactive UI elements with their properties and positions
Extract visible text content
Get comprehensive window and target information via Chrome DevTools Protocol.
Get organized overview of all page elements (buttons, inputs, selects, links)
Get document title
Get current URL
Launch an Electron application with debugging capabilities.
Stream application logs from main process, renderer, and console.
Select dropdown options by value or visible text
Execute JavaScript commands in the running Electron application via WebSocket.
Capture high-quality screenshots using Playwright and Chrome DevTools Protocol.