How to Add a Website Image Thumbnail for Social Media Sharing

Abhinav KumarAbhinav Kumar
4 min read

If you have a website that you want to share on social media platforms like Facebook, LinkedIn, or Twitter, you might want to add a website image thumbnail that shows up when someone clicks on your link. A website image thumbnail is a small preview of your website that gives a glimpse of what it is about and attracts more attention from potential visitors. In this article, I will show you how to add a website image thumbnail for your HTML site in four easy steps.

Step 1: Prepare Your Image

The first step is to prepare the image that you want to use as your website thumbnail. The image should be relevant to your website content and have the following properties:

  • Max file size: 5 MB

  • Minimum image dimensions: 1200 (w) x 627 (h) pixels

  • Recommended ratio: 1.91:1

These properties are important because they ensure that your image will display properly on different social media platforms and devices. If your image does not meet these requirements, you might need to resize or crop it using image editing software.

Step 2: Upload Your Image

The next step is to upload your image to a free image-hosting website. This will make it easier for you to access your image URL later and avoid any image location problems. There are many free image hosting websites available online, but one that I recommend is ImgBB — Upload Image — Free Image Hosting. To upload your image to Image BB, follow these steps:

  • Go to ImgBB — Upload Image — Free Image Hosting and click on the “Start Uploading” button.

  • Choose your image file from your computer or drag and drop it into the upload area.

  • Once your image is uploaded, you will see a page with various links and codes for your image. Copy the link under the “Viewer Links” section and paste it into a new tab in your browser.

  • You should see your image alone on the new tab. Right-click on the image and select “Copy Image Address”. This will copy the correct image URL to your clipboard. It should look something like this:

    https://YOUR_BB_URL_LINK/YOUR_IMAGE.png

Step 3: Add Meta Tags to Your Website

The third step is to add some meta tags to your website that will tell social media platforms what information to display when someone shares your link. Meta tags are snippets of code that go inside the <head> tags of your HTML file. You need to add the following meta tags and replace the parts in bold with your own information:

<meta property='og:title' content='<TITLE OF YOUR WEBSITE>' />
<meta property='og:image' content='<https://YOUR_BB_URL_LINK/YOUR_IMAGE.png>' />
<meta property='og:description' content='DESCRIPTION' />
<meta property='og:url' content='URL OF YOUR WEBSITE' />
<meta property='og:image:width' content='1200' />
<meta property='og:image:height' content='627' />
<!-- TYPE BELOW IS PROBABLY: 'website' or 'article' or look on https://ogp.me/#types -->
<meta property="og:type" content='website' />

These meta tags use the Open Graph protocol, which is a standard way of defining how web pages are represented on social media platforms. The most important meta tags are og:title, og:image, og:description, and og:url, which specifies the title, image, description, and URL of your website respectively. The other meta tags are optional but recommended for better performance and compatibility.

Step 4: Test Your Website Thumbnail

The final step is to test your website thumbnail and see how it looks on different social media platforms. You can use the following tools to check if your meta tags are working correctly and if there are any errors or warnings:

You can also test your website thumbnail by sending a message to a friend on any of these platforms and seeing how it appears on their device.

That’s it! You have successfully added a website image thumbnail for social media sharing. I hope this article was helpful and informative. If you have any questions or feedback, please let me know in the comments below. Thank you for reading! 😊

0
Subscribe to my newsletter

Read articles from Abhinav Kumar directly inside your inbox. Subscribe to the newsletter, and don't miss out.

Written by

Abhinav Kumar
Abhinav Kumar