chrome-screenshot for Openclaw

A command-line utility to capture full-page screenshots and PDF documents from local HTML files using system-installed Chrome.

cclam5
v1.0.0
May 10, 2026
0
686
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install chrome-screenshot

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install chrome-screenshot using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is chrome-screenshot?

The chrome-screenshot skill is a specialized tool designed to bridge the gap between HTML content and static media formats. By utilizing puppeteer-core and the existing Chrome installation on your machine, it provides a reliable way for AI agents to generate visual outputs from code. This integration is a core part of the Openclaw Skills ecosystem, allowing for the generation of reports, visualizations, and shareable snapshots without requiring a full browser environment download.

Because it runs locally, it is exceptionally fast and secure, making it ideal for processing sensitive data-driven reports into shareable formats like PNG or PDF. It simplifies the workflow of capturing web content by handling the local server setup and teardown automatically.

chrome-screenshot Use Cases

  • Converting data-intensive HTML reports into shareable PNG images.
  • Generating PDF documents from local templates for professional distribution.
  • Creating mobile-ready screenshots for integration into messaging apps or dashboards.
  • Automating visual regression snapshots of locally developed frontend components.

How chrome-screenshot Works

  1. A local Python-based HTTP server is started on port 8877 to serve the specified HTML file.
  2. The skill invokes a headless instance of Google Chrome via the puppeteer-core library.
  3. The browser navigates to the local server and executes a full-page measurement to ensure no content is clipped.
  4. A screenshot is captured or a PDF is printed to the target output directory.
  5. The local HTTP server is terminated and the browser process is closed.

chrome-screenshot Setup

To use this within the Openclaw Skills environment, ensure you have the following prerequisites installed:

# Install puppeteer-core globally
npm install -g puppeteer-core

# Ensure Python 3 is available for the local server
python3 --version

# The script expects Chrome at this macOS path:
# /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

chrome-screenshot Data Schema & Taxonomy

Argument Description Default Value
html-file Path to the input HTML file (Required)
output-path Path for the resulting file /tmp/screenshot.png
width The viewport width in pixels 420

chrome-screenshot Advanced Features

  • Dual Output Support: Automatically switches between PNG screenshotting and PDF printing based on the file extension.
  • Dynamic Viewport Scaling: Control the width of the capture to optimize for different display formats.
  • Zero-Download Footprint: Utilizes your existing Chrome browser, avoiding the typical large Chromium download associated with standard Puppeteer installations.
  • Local Server Integration: Uses a temporary Python server to ensure local assets and CSS are rendered correctly by the browser engine.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*