← Projects

Laravel OG Kit

v0.3.0

Dynamic OG images for Laravel, designed in your own HTML and CSS.

composer require mischasigtermans/laravel-ogkit

What it does

  • From a controller or from Blade

    Set a template with $ogkit->template() in a controller or Livewire component, or put an <x-ogkit-template> component in a view. @ogkit in your head outputs the og: and twitter: meta tags.

  • Templates to start from

    Blog posts, product pages with prices, author cards, docs and repositories. Each takes its own fields, such as title, image, price or readingTime.

  • Or your own HTML

    Write a custom template in Blade with Tailwind classes, colour props and og- utility classes. Pick any Google Font, a secondary font, and a background pattern or gradient.

  • Preview before you share

    Set OGKIT_PREVIEW=true and every HTML response gets an OG Preview button that shows exactly what will be screenshotted.

  • A version for cache busting

    The @ogkitUrl directive and $ogkit->imageUrl() take a version, so a changed design can get a fresh image URL.

Install Laravel OG Kit.

Hi, I'm Mischa. I've been shipping products and building ventures for over a decade. First exit at 25, second at 30. Now Partner & CPO at Ryde Ventures, an AI venture studio in Amsterdam. Currently shipping Stagent, TAP and Steddle. I write about what I learn along the way. More about me.

You might also enjoy: Nightshift: why Friday's gig is on Saturday.

← Projects