solvit.io

HTML tags that make a website look better when sharing URLs on Facebook

<!-- ... -->
<head>
    <!-- ... -->

    <!-- recommended tags for all pages -->
    <meta property="fb:app_id" content="1234567" />
    <meta property="og:url" content="http://example.org/page.html" />
    <meta property="og:title" content="Lorem Ipsum Dolor Sit Amet" />
    <meta property="og:description" content="Lorem Ipsum ..." />
    <meta property="og:site_name" content="Example" />
    <meta property="og:image" content="http://example.org/image.png" />

    <!-- optional tags -->
    <meta property="og:type" content="article" />
    <meta property="og:locale" content="en_US" />
</head>
<!-- ... -->

Recommended tags:

  • fb:app_id, the ID displayed in the dashboard of your Facebook application.
  • ogg:url, the canonical URL where Likes and Shares are aggregated. Use the same URL for desktop and mobile pages.
  • og:title, the title of the content without your branding (company name, etc.)
  • og:description, brief description of the content (2 to 4 paragraphs).
  • og:site_name, the name of your site (Example not example.org).
  • og:image, the image displayed when someone shares this page on Facebook.

Optional tags:

Useful Resources

Find more solutions about: , , ,