Quickstart

Build a URL, get a PNG. That's the entire API.

https://api.opengraphapi.com/v1/card?template=blog-og&title=Hello+World&subtitle=My+first+card&bg=sunset

Open it in a browser — that's your image. Use it anywhere an image URL works:

<meta property="og:image" content="https://api.opengraphapi.com/v1/card?template=blog-og&title=${encodeURIComponent(post.title)}">

Parameters

ParameterDescriptionExample
templateOne of the 30 templates (see below). Default blog-og.template=certificate
titleMain text (required for most templates)title=Jane+Doe
subtitleSecondary line (meaning varies per template)subtitle=SEO+Masterclass
metaTertiary field: date / episode / handle / starsmeta=Sep+2026
brandBrand or issuer name shown in the headerbrand=Acme
price / badgeUsed by product / announcementprice=$49
bgTheme: midnight, sunset, forest, royal, slate, ocean, mono, rose, amber, paperbg=royal
imageProduct photo URL (jpg/png/webp, ≤4MB) — used by the product templateimage=https://…/p.jpg
api_keyRaises quota; watermark stays on the free plan onlyapi_key=og_xxx

Templates

Machine-readable list: GET /v1/templates

amp;A card
TemplateBest for
blog-ogArticle / blog share cards
quoteSocial quotes, testimonials
announcementProduct launches, release notes
productE-commerce listings with price tag
certificateCourse completion, awards (per-user URLs)
eventMeetups, webinars, conferences
podcastEpisode art with guest + episode no.
statBig-number marketing stats
changelogVersion releases
youtubeVideo thumbnails / tutorials
tweetTweet-style quote cards
articleMinimal editorial (light theme)
newsletterIssue covers
jobHiring cards
githubRepo share cards
testimonialTestimonial with star row
price-dropSale card with old price struck
producthuntPH launch card with upvotes
hackernewsHN front-page story card
discordServer announcement banner
reviewReview score card
countdownUrgency countdown
realestateProperty listing
webinarWebinar promo
courseCourse lesson progress
linkedinLinkedIn post card
codeCode snippet card
comparisonA vs B comparison
faqQ
githubRepo share cards
milestoneAchievement card

API keys & limits

Without a key you get 300 images/day per IP with a small watermark. Your own key from /start/ is free too — magic link, about 60 seconds, no card, and the 300/day is counted per key instead of per shared IP. Need more? Starter $19/mo (500/day) and Growth $49/mo (3,000/day) guarantee watermark-free renders, private caching and email support. Self-serve checkout is live.

Responses include an x-ratelimit-remaining header. When the daily quota is exhausted the API returns HTTP 429 until the next UTC day.

Recipes

# cURL — save a certificate
curl -o cert.png "https://api.opengraphapi.com/v1/card?template=certificate&title=Jane+Doe&subtitle=SEO+Course&api_key=YOUR_KEY"

# JavaScript — dynamic OG image in Next.js / Astro
export function ogImageUrl(title: string) {
  const u = new URL("https://api.opengraphapi.com/v1/card");
  u.searchParams.set("template", "blog-og");
  u.searchParams.set("title", title);
  u.searchParams.set("api_key", process.env.OG_API_KEY!);
  return u.toString();
}

# Python — batch product images
import requests, urllib.parse
for name, price in products:
    url = "https://api.opengraphapi.com/v1/card?" + urllib.parse.urlencode(
        {"template": "product", "title": name, "price": price, "api_key": KEY})
    open(f"{name}.png", "wb").write(requests.get(url).content)