🎩 You're Invited:Meet the Socket team at Black Hat in Las Vegas, August 3-6.RSVP
Sign In

spa-reader-mcp

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

spa-reader-mcp

MCP Server that renders JavaScript SPA pages and extracts LLM-ready Markdown content

latest
Source
npmnpm
Version
1.0.3
Version published
Maintainers
1
Created
Source

spa-reader-mcp

CI npm version

MCP server that renders JavaScript SPA pages and extracts Markdown via headless Chromium.

Traditional scrapers fail on SPAs because content is rendered client-side. This tool launches Playwright, waits for JS to finish, then extracts clean Markdown using Readability + Turndown.

Install

npx playwright install chromium

Claude Desktop

{
  "mcpServers": {
    "spa-reader": {
      "command": "npx",
      "args": ["-y", "spa-reader-mcp"]
    }
  }
}

Claude Code

claude mcp add spa-reader -- npx -y spa-reader-mcp

Tools

spa_read

Render a page and extract content as Markdown.

ParameterTypeDefaultDescription
urlstringURL to read (required)
waitForSelectorstringCSS selector to wait for
waitTimeoutnumber30000Timeout in ms
includeMetadatabooleantrueAdd YAML frontmatter
cookiesarrayCookies for auth
headersobjectCustom HTTP headers

spa_screenshot

Capture a PNG screenshot after JS rendering.

ParameterTypeDefaultDescription
urlstringURL to capture (required)
waitForSelectorstringCSS selector to wait for
waitTimeoutnumber30000Timeout in ms
widthnumber1280Viewport width
heightnumber720Viewport height
fullPagebooleanfalseFull page capture
cookiesarrayCookies for auth
headersobjectCustom HTTP headers

Security

  • SSRF protection: blocks private/loopback IPs
  • Only http: and https: schemes allowed
  • Selector injection prevention
  • Content capped at 100KB

Dev

pnpm install && pnpm build
pnpm test

License

MIT

Keywords

mcp

FAQs

Package last updated on 17 Mar 2026

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts