Dynamic OG Images for Hugo Sites

Generate branded social cards for every Hugo post automatically. No JavaScript required.

Get Started

Pure Go

Works natively with Hugo's Go templating—no JavaScript or external dependencies.

Template Native

Use Hugo variables like .Title directly in your image generation.

Any Host

Compatible with GitHub Pages, Netlify, Cloudflare, and self-hosted deployments.

Example Integration

{{/* layouts/partials/og-image.html */}}
{{ $title := .Title | urlquery }}
{{ $key := getenv "IMAGO_API_KEY" }}
{{ $ogUrl := printf "https://imagoapi.com/api/og/generate?title=%s&template=modern&api_key=%s" $title $key }}
<meta property="og:image" content="{{ $ogUrl }}" />
<meta name="twitter:image" content="{{ $ogUrl }}" />
<meta name="twitter:card" content="summary_large_image" />

Ready to improve your social shares?

Join thousands of developers using Imago API for stunning OG images.

Start Building Free