Instant QR code smart links with rich previews β powered by Cloudflare Workers.
QRClaw generates shareable QR code pages from any string or URL. Each QR code gets a smart link with full Open Graph and Twitter Card metadata for rich previews when shared on social media, messaging apps, or embedded anywhere.
Built to solve the QR code rendering problem in agentic tools like OpenClaw, Claude Code, Copilot, and other CLI/UI agents.
- Instant edge generation β QR codes created in milliseconds on Cloudflare Workers
- Smart links β each QR gets a unique URL with rich social previews (OG + Twitter Cards)
- UTF-8 + Image β dual rendering: scannable image for web, UTF-8 block characters for terminals
- 24h TTL β links auto-expire, keeping things clean and ephemeral
- Copy everything β one-click copy for image, UTF-8 text, source data, and smart link
- Content negotiation β returns JSON for API clients (
Accept: application/json), redirects browsers to the QR page
Visit https://qrclaw.goplausible.xyz, paste any text or URL, and hit Generate.
# Browser or curl β redirects to the smart link page
curl -L "https://qrclaw.goplausible.xyz/?q=https://example.com"
# JSON response for programmatic use
curl -H "Accept: application/json" "https://qrclaw.goplausible.xyz/?q=https://example.com"JSON response:
{
"link": "https://qrclaw.goplausible.xyz/q/abc123...",
"qr": "βββββββ ...",
"data": "https://example.com",
"expires_in": "24h"
}Any MCP-compatible agent can call QRClaw via HTTP:
GET https://qrclaw.goplausible.xyz/?q=<your-string>
Accept: application/json
The response includes a qr field with UTF-8 block characters that render directly in terminal-based agents, plus a link field for the full smart link page.
| Method | Path | Description |
|---|---|---|
GET |
/?q=<string> |
Generate QR code. Redirects browsers to smart link; returns JSON for API clients. |
GET |
/q/:uuid |
Smart link page with image/UTF-8 toggle, copy buttons, and social preview metadata. |
GET |
/image/:uuid.jpeg |
Raw QR code JPEG image. |
GET |
/ |
Landing page (when no q parameter). |
Each generated QR code gets a dedicated page with:
- Image view β high-quality scannable JPEG QR code
- UTF-8 view β terminal-friendly block character rendering
- Copy buttons β copy image, UTF-8 text, original data, or page link
- Rich previews β Open Graph and Twitter Card meta tags for social sharing
- 24h expiry β auto-cleanup via Cloudflare KV TTL
βββββββββββ GET /?q=hello ββββββββββββββββββββ
β Client β βββββββββββββββββββΆ β Cloudflare Worker β
βββββββββββ β β
β 1. Generate QR β
β @juit/qrcode β
β + @cf-wasm/ β
β photon β
β β
β 2. Build HTML β
β with OG meta β
β β
β 3. Store in KV β
β (24h TTL) β
β β
β 4. Return link β
β or redirect β
ββββββββββ¬ββββββββββββ
β
ββββββββββΌββββββββββββ
β Cloudflare KV β
β β
β page--<uuid> HTML β
β image--<uuid> JPEG β
β (base64) β
βββββββββββββββββββββββ
- Node.js (v18+)
- Wrangler CLI (
npm i -g wrangler) - A Cloudflare account with Workers and KV enabled
git clone https://github.com/GoPlausible/qrclaw.git
cd qrclaw
npm installnpm run dev
# β http://localhost:8787npm run deploywrangler.toml:
name = "qrclaw"
main = "src/index.ts"
compatibility_date = "2025-03-18"
compatibility_flags = ["nodejs_compat"]
[route]
pattern = "qrclaw.yourdomain.com/*"
zone_id = "your-zone-id"
[[kv_namespaces]]
binding = "QRCLAW_KV"
id = "your-kv-namespace-id"| Variable | Description | Default |
|---|---|---|
BASE_URL |
Public base URL for generated links | Auto-detected from request origin |
| Package | Purpose |
|---|---|
@juit/qrcode |
QR code generation (PNG) β zero-dependency, Workers-compatible |
qrcode |
QR matrix generation for UTF-8 rendering via QRCode.create() |
@cf-wasm/photon |
Image processing (PNG β JPEG conversion) on Workers |
- 5 QR codes per minute per IP address
- Configured via Cloudflare Dashboard β Security β WAF β Rate limiting rules
- Blocks at the edge before the Worker runs β no code changes needed
- Exceeding the limit returns HTTP 429 (Too Many Requests)
- Input is trimmed of leading/trailing whitespace
- Empty input returns 400 with a JSON error
- Maximum input length: 2048 characters (QR codes with high error correction can't encode more)
QRClaw includes an agent skill that teaches AI assistants (Claude Code, OpenClaw, Copilot, etc.) how to use the QRClaw API. There are several ways to install it:
npx clawhub install qrclawThe skill will be available immediately for your OpenClaw agent to use.
npx skills add GoPlausible/qrclawThis downloads and installs the QRClaw skill into your agent's skill directory.
Copy the skill/ directory from this repo into your agent's skills folder:
# Claude Code
cp -r skill/SKILL.md ~/.claude/skills/qrclaw/SKILL.md
# Or clone and symlink
git clone https://github.com/GoPlausible/qrclaw.git
ln -s "$(pwd)/qrclaw/skill" ~/.claude/skills/qrclawMIT β built by GoPlausible