Ad

Shopify + Og:image Resulting In "was Not A Valid URL."

- 1 answer

This is the code:

<meta property="og:image" content="{{ 'logo.png' | asset_url }}" />

As you can see, I do have the file:

enter image description here

But if you check in the Facebook Debugger, you'll see this:

Provided og:image URL, //cdn.shopify.com/s/files/1/1318/9093/t/10/assets/logo.png?15320454113946669981 was not a valid URL.

Why is this problem and how to solve it?

Direct URL of the logo: https://cdn.shopify.com/s/files/1/1318/9093/t/10/assets/logo.png?15320454113946669981

Ad

Answer

Try this <meta property="og:image" content="https://{{ 'logo.png' | asset_url }}" />

Facebook scraper requires the transfer protocol to be specified.

Ad
source: stackoverflow.com
Ad