Choosing the thumbnail image that shows up on Facebook

Facebook "like", "share" or "send" buttons are a nice way to let your visitors share content from your website.

When I put a Facebook button on my site I noticed that it generated a thumbnail next to the shared content. Most of the time this thumbnail was a random image from the page that didn't correlate with the shared content. It turns out you can specify what image you would like Facebook to display with a meta tag in your page:

<meta property="og:image" content="url to image" />

Replace "url to image" up there with your image path and you're good to go. If you don't have this code, Facebook will automatically choose an image from your page.

Like this post? Share it with others!