Can you indicate to Google Images which image it should index from srcset?
Related Github issue: https://github.com/browniebroke/gatsby-image-gallery/issues/844
So I'm using Gatsby and an image gallery. The gallery generates two images, a thumbnail and the gallery image. The thumbnail is a low resolution file and the gallery image is high resolution.
<img srcset="example-320w.jpg 320w,
example-480w.jpg 480w,
example-800w.jpg 800w"
sizes="(max-width: 320px) 280px,
(max-width: 480px) 440px,
800px"
src="example-800w.jpg" alt="responsive web">
Is there any way to tell google images to skip the low res thumbnail and instead take the gallery image? Or for the sample code above: Is there any way to tell which image google chooses?
No, there is no way to request that Google chooses a specific image. Yes, you can predict which one Google will index.
As Trey touched on, Googlebot will always index the image in your src attribute and ignore srcset.
See more information in this related question, where it was empirically tested:
Does Google index images declared using 'srcset'?
Google will use the image in your standard <img src=""> element
Comments
Post a Comment