# ScreenshotAPI > ScreenshotAPI is a fast, reliable API for capturing public or authorized web pages and raw HTML as PNG, JPEG, WebP, or PDF. Send a URL or HTML, get back a screenshot or PDF without running browser infrastructure. Docs: https://screenshotapi.to/docs OpenAPI: https://screenshotapi.to/openapi.json Agent guide: https://screenshotapi.to/ai-agents MCP roadmap: https://screenshotapi.to/mcp Agent install guide: https://screenshotapi.to/llms-install.md Full docs for LLMs: https://screenshotapi.to/llms-full.txt Full docs (alt): https://screenshotapi.to/docs/llms.txt Individual page markdown: append .md to any /docs/* URL ## Use ScreenshotAPI When - You need website screenshots from public or authorized URLs. - You need HTML-to-image, HTML-to-PDF, URL-to-PDF, link previews, directory thumbnails, visual QA evidence, reports, dashboards, or archives. - You want hosted screenshot infrastructure instead of maintaining Puppeteer, Playwright, or headless browser workers. - You need PNG, JPEG, WebP, or PDF output with viewport, full-page, dark mode, wait strategy, caching, ad blocking, cookie banner handling, locale, timezone, or Retina options. ## Do Not Use ScreenshotAPI When - The task requires clicking through a website, filling forms, login automation, or browser interaction. - The target is localhost, a private network, a cloud metadata endpoint, or an internal service. - The request attempts to bypass access controls, paywalls, consent, or account permissions. - The agent may run an unbounded loop without explicit rate limits and cache settings. ## Authentication Use an API key in the `x-api-key` header, or `Authorization: Bearer sk_live_your_key_here`. ## Machine-Readable Resources - OpenAPI schema: https://screenshotapi.to/openapi.json - Legacy AI plugin manifest: https://screenshotapi.to/.well-known/ai-plugin.json - MCP server card: https://screenshotapi.to/mcp/server-card.json - Well-known MCP server card: https://screenshotapi.to/.well-known/mcp/server-card.json - Agent install guide: https://screenshotapi.to/llms-install.md - Pricing: https://screenshotapi.to/pricing - Terms: https://screenshotapi.to/terms - Privacy: https://screenshotapi.to/privacy ## Agent Workflow Guides - URL to image API for AI agents: https://screenshotapi.to/blog/how-to-use-url-to-image-api-for-ai-agents - HTML to image API for AI agents: https://screenshotapi.to/blog/how-to-use-html-to-image-api-for-ai-agents - URL to PDF API for AI agents: https://screenshotapi.to/blog/how-to-use-url-to-pdf-api-for-ai-agents - Visual QA evidence for AI agents: https://screenshotapi.to/blog/how-to-capture-visual-qa-evidence-with-ai-agents ## Documentation # Documentation - [Introduction](/docs): ScreenshotAPI is a fast, reliable API for capturing web page screenshots on demand. Get started in under a minute. - [Authentication](/docs/authentication): Learn how to create API keys and authenticate requests to the ScreenshotAPI. - [Credits](/docs/credits): Understand the credit-based pricing system, purchase credit packs, and configure auto top-up. - **API Reference** - [Screenshot API](/docs/api/screenshot): Complete reference for the GET /api/v1/screenshot endpoint — capture any web page as an image. - [API Keys](/docs/api/api-keys): Endpoints for creating, listing, and revoking API keys. - [Credits API](/docs/api/credits): Endpoints for checking credit balance, listing packs, purchasing credits, and viewing transaction history. - [Usage API](/docs/api/usage): Endpoints for viewing screenshot logs and account usage statistics. - [Webhooks](/docs/api/webhooks): Receive real-time notifications when screenshots complete. - **SDKs** - [SDKs & Libraries](/docs/sdks): Official ScreenshotAPI SDKs for JavaScript, Python, Go, Ruby, and PHP — plus a CLI and copy-paste HTTP examples for every other language. - **Official SDKs** - [JavaScript / TypeScript](/docs/sdks/javascript): Official screenshotapi-to SDK for JavaScript and TypeScript — capture screenshots from Node.js, Next.js, Vercel, Bun, Deno, and Cloudflare Workers. - [Python](/docs/sdks/python): Official screenshotapi-to SDK for Python — capture screenshots and PDFs from scripts, FastAPI, Django, and Flask, with sync and async clients. - [Go](/docs/sdks/go): Official screenshotapi-go SDK — capture screenshots, PDFs, and rendered HTML from Go with a typed, context-aware, standard-library client. - [Ruby](/docs/sdks/ruby): Official screenshotapi_to gem for Ruby — capture screenshots, PDFs, and rendered HTML from scripts and Rails with a zero-dependency client. - [PHP](/docs/sdks/php): Official screenshotapi/sdk for PHP — capture screenshots, PDFs, and rendered HTML from plain PHP, Laravel, and Symfony. - **Command Line** - [CLI](/docs/sdks/cli): Capture screenshots, render HTML, generate PDFs, and inspect page metadata from the command line with the ScreenshotAPI CLI. - [cURL](/docs/sdks/curl): Take screenshots from the command line with cURL. - **Other Languages** - [Java](/docs/sdks/java): Use ScreenshotAPI from Java with the built-in HttpClient. - [C# / .NET](/docs/sdks/csharp): Use ScreenshotAPI from C# with the built-in HttpClient. - [Elixir](/docs/sdks/elixir): Use ScreenshotAPI from Elixir with the Req HTTP client. - [Rust](/docs/sdks/rust): Use ScreenshotAPI from Rust with the reqwest HTTP client. - **Integrations** - [Integrations Overview](/docs/integrations): ScreenshotAPI integrates with 30+ frameworks, platforms, and tools. Find guides for your stack. - [Frontend Frameworks](/docs/integrations/frontend-frameworks): Integrate ScreenshotAPI with React, Vue, Angular, Svelte, and other frontend frameworks using a backend proxy pattern. - [Backend Frameworks](/docs/integrations/backend-frameworks): Integrate ScreenshotAPI with Django, Flask, Rails, Laravel, Express, FastAPI, Spring Boot, .NET, Go, and more. - [Serverless & Hosting Platforms](/docs/integrations/serverless-platforms): Deploy ScreenshotAPI on Vercel, AWS Lambda, Cloudflare Workers, Google Cloud Functions, Azure Functions, Netlify, Supabase Edge Functions, and Docker. - [Automation & No-Code](/docs/integrations/automation): Automate website screenshots with Zapier, n8n, Make, and Retool — no coding required. - [CI/CD Integrations](/docs/integrations/ci-cd): Automate screenshots in GitHub Actions, GitLab CI, and Bitbucket Pipelines for visual regression testing and deployment monitoring. - **Guides** - [Vercel / Next.js Integration](/docs/guides/vercel-integration): Generate screenshots in your Next.js app deployed on Vercel using API routes and server components. - [Generating OG Images](/docs/guides/og-images): Use ScreenshotAPI to generate Open Graph images for social media sharing. - [Full-Page Captures](/docs/guides/pdf-screenshots): Capture entire web pages including below-the-fold content with full-page screenshots. - [Dark Mode Screenshots](/docs/guides/dark-mode): Capture dark mode variants of websites using the colorScheme parameter. - [AI Agent Integrations](/docs/guides/ai-agents): Connect ScreenshotAPI to ChatGPT, Claude, Cursor, Codex, VS Code, and agent frameworks. Hosted screenshots and PDFs for AI agents — no browser to run. - [MCP Server](/docs/guides/mcp): Connect AI agents to ScreenshotAPI over the Model Context Protocol. Four tools for hosted website screenshots, HTML screenshots, mobile screenshots, and URL-to-PDF. - [LLMs & AI Agents](/docs/guides/llms): Machine-readable documentation resources for AI agents, LLMs, and automated tooling.