NMC Pro

Post Detail

Boosting Website SEO and Social Sharing with Open Graph, Schema.org and JSON-LD

Boosting Website SEO and Social Sharing with Open Graph, Schema.org and JSON-LD

Standard <title> and <meta name="description"> tags are no longer enough for modern SEO. To maximize visibility on search engines and engagement on social platforms, your website needs three complementary layers: Open Graph for rich social previews, Schema.org to give search engines semantic context, and JSON-LD to deliver that structured data cleanly without cluttering your HTML.


Why Basic Meta Tags Are No Longer Enough

When you publish a web page, two very different types of machines read it:

  1. Social & Messaging Crawlers (Facebook, LinkedIn, X/Twitter, Slack, Discord, Telegram, WhatsApp) looking for a title, summary, and thumbnail to build a link preview card.

  2. Search Engine Crawlers (Googlebot, Bingbot) trying to understand what the page actually represents—is it a news article, a job opening, a software product, or a company profile?

Without explicit structured metadata, crawlers have to guess. Social apps might grab a random navigation icon as your thumbnail, and search engines will show plain blue links instead of rich, high-converting snippets.

Technology

What It Is

Primary Consumer

Core Benefit

Open Graph (OG)

Metadata protocol for link previews

Social networks & chat apps

Turns raw URLs into visual preview cards, increasing Click-Through Rate (CTR).

Schema.org

Universal semantic vocabulary

Search engines (Google, Bing)

Removes ambiguity about page entities to unlock Google Rich Results.

JSON-LD

Serialization format for Schema.org

Search engine crawlers

Decouples SEO data from HTML/CSS, keeping templates clean and maintainable.


What Is Open Graph?

Originally introduced by Facebook and now supported by virtually every social network and messaging app, the Open Graph (OG) protocol uses <meta property="og:..."> tags in your <head> to define exactly how a shared URL should be rendered.

Essential Open Graph Tags

Here is a production-ready Open Graph baseline for an article page:

```html

```

Best Practices for Open Graph

  • Always use absolute URLs for og:image and og:url (e.g., https://example.com/images/cover.jpg, never /images/cover.jpg).

  • Use a 1200Ă—630 px image (1.91:1 aspect ratio) for summary_large_image cards so images are not cropped awkwardly.

  • Provide a brand fallback image so pages without a custom thumbnail still look professional when shared.

  • Keep og:title under 60–70 characters and og:description under 155–160 characters to avoid truncation.


2. Schema.org: Giving Search Engines Semantic Context

What Is Schema.org?

Schema.org is a collaborative, universal vocabulary founded by Google, Microsoft, Yahoo, and Yandex. It defines standardized entity types (Organization, BlogPosting, Product, JobPosting, BreadcrumbList, etc.) and their properties.

Consider this raw HTML snippet: ```html

Senior Backend Engineer - Hanoi - Full Time

`` A crawler only sees plain text. It cannot be 100% sure whether this is an active job vacancy, a career blog post, or a candidate's resume. With Schema.org, you declare explicitly: *"This page is aJobPostingoffered byOrganizationX in Hanoi forFULL_TIME` employment."*

High-Impact Schema Types to Implement

  1. Organization & WebSite (Home Page): Connects your brand name, official logo, contact points, and internal search bar (SearchAction) to Google's Knowledge Graph.

  2. BreadcrumbList (All Subpages): Replaces ugly raw URLs in search results with clean navigation paths (Home > Blog > Engineering > SEO Guide).

  3. BlogPosting / Article (Blog Posts): Qualifies articles for rich news features with headline, image, author, and publication/modification dates.

  4. Product & Service (Catalog Pages): Helps search engines index your offerings with brand/provider attribution and descriptions.

  5. JobPosting (Careers Pages): Enables eligibility for the Google for Jobs interactive widget at the top of search results.


3. JSON-LD: The Cleanest Way to Deliver Schema.org

Why JSON-LD Over Microdata?

In the past, developers embedded Schema.org directly inside HTML elements using Microdata (itemscope, itemtype, itemprop). That tightly coupled SEO metadata to DOM structure—refactoring a CSS wrapper or Blade component could silently break structured data.

JSON-LD (JavaScript Object Notation for Linked Data) solves this by placing all structured data inside a single <script type="application/ld+json"> block in the <head>:

  • Separation of concerns: UI/CSS changes never break SEO schemas.

  • Easy to generate dynamically: Backend services can build and serialize PHP/Node/Python arrays directly to JSON.

  • Google's recommended format: Explicitly preferred by Google Search documentation.

Example 1: Home Page (Organization + WebSite Graph)

Using @graph lets you link multiple entities together cleanly in one block:

```html

```

Example 2: Blog Post (BlogPosting + BreadcrumbList)

```html

```


4. Putting It All Together: Complete Technical SEO Checklist

For an end-to-end production setup, pair Open Graph and JSON-LD with foundational HTML metadata:

  1. Dynamic <html lang="...">: Match the active page language (en, vi, etc.).

  2. Canonical URLs (<link rel="canonical" ...>): Prevent duplicate content penalties caused by query parameters or syndicated URLs.

  3. Multi-language hreflang Alternates: html <link rel="alternate" hreflang="en" href="https://example.com/post/1/seo-guide?lang=en"> <link rel="alternate" hreflang="vi" href="https://example.com/post/1/seo-guide?lang=vi"> <link rel="alternate" hreflang="x-default" href="https://example.com/post/1/seo-guide">

  4. Smart robots Directives:

  5. Standard content pages: index, follow

  6. Internal search results (/posts?search=...): noindex, follow

  7. Application forms & 404/error pages: noindex, nofollow

  8. Custom Overrides for Editors: Automatically generate defaults from page titles, stripped HTML excerpts, and thumbnails, while allowing CMS editors to override meta_title, meta_description, canonical_url, and no_index per post or page.


How to Validate Your Implementation

Before shipping to production, test your pages with these official validators:

  • Google Rich Results Test: Verify that your JSON-LD BlogPosting, JobPosting, Product, and BreadcrumbList schemas are eligible for rich snippets.

  • Schema Markup Validator: Check syntax and Schema.org compliance across all @graph entities.

  • Facebook Sharing Debugger / LinkedIn Post Inspector: Inspect how Open Graph titles, descriptions, and og:image previews render when shared.

If you think this is useful, let's comment your opinion below.

0 Comments

No comments yet. Be the first to share your thoughts!

Leave a Comment

0 / 1500 characters

AI Assistant

Online

Press Enter to send · Shift+Enter for new line