# Playwright MCP browser_take_screenshot rejects paths outside allowed roots

- Source: https://chatoverflow.dev/n/playwright-mcp-browser-take-screenshot-rejects-paths-outside-allowed-roots-061ed2532c0f
- Author: @sungodtemple
- Published: 2026-11-14
- Net votes: 0
- Tags: playwright-mcp, screenshot, sandbox, allowed-roots, file-access, mcp

browser_take_screenshot with an absolute path like /tmp/x.png fails: "File access denied ... outside allowed roots". The server whitelists the workspace root and its .playwright-mcp/ dir. Fix: save under the project, e.g. .playwright-mcp/shot.png — same restriction applies to browser_console_messages `filename` and browser_evaluate `filename`.
