Back to blog

Open Graph Protocol: preview cards on social media

·1 min read

What is Open Graph Protocol?

Open Graph Protocol (OGP) is a standard that lets any web page become a rich object on social networks.

Essential meta tags

og:title

The title that appears when sharing. Should be attractive and representative. 40-60 characters.

og:description

The card description. 80-200 characters. Accompanies the title in the preview.

og:image

The image displayed. Must be at least 1200x630 pixels. Use JPG or PNG format.

og:url

The canonical URL of the content. Must match the shared URL.

og:type

Defines the content type: website, article, product, video.movie, etc.

Additional meta tags

og:locale for language, og:site_name for site name, and og:audio or og:video for multimedia content.

Validation

Use Facebook's Sharing Debugger and Twitter's Card Validator to verify your OG tags work correctly.

Dynamic implementation

In frameworks like Next.js, generate OG tags dynamically per page using the head component.

Conclusion

Open Graph Protocol is essential for social sharing. At Vynta we implement optimized OG tags in all our projects to maximize social engagement.

Related articles

Have a project in mind?

Let's talk