Do ImageOptomize and SEOmatic work together - or to be more specific do I need an image variant for the social and SEO images defined in SEOmatic?

  • I have been importing content into a News entry.
  • I am defining my image variations using imageOptimize on the News Volume.
  • I have a "meta image" asset field which is being used to serve the SEO and Social Media images to SEOmatic's SEO settings for the entry.

Before installing and using imageOptimize the meta image previews were working fine with SEOmatic in the entry editor. Now they are not getting picked up... do I need to define an image variant that matches the SEO and Meta image sizes?

Also... SEOmatic is such a time saver, I estimate I have saved at least two weeks dev time with this plugin. Thank you Andrew!

enter image description here

  • So one doesn't really have anything to do with the other... Image Optimize shouldn't interfere with anything SEOmatic is doing. SEOmatic does its own image transforms on the images. Are you using the latest versions of both? Commented Dec 11, 2018 at 20:11
  • btw, you can inspect the previews on the right there using your browser developer tools. See what URL the background-image is set to for the previews. Might give you clues as to what isn't working, and why. Commented Dec 11, 2018 at 20:20

1 Answer 1


I've used SEOmatic and ImageOptimize together before and never had those issues. SEOmatic should care less about the presence of the ImageOptimize field on the asset and you definitely don't need to specify custom ImageOptimize variants for your SEO/social purposes. SEOmatic grabs the raw image (like you would grab the asset url in the templates) and does its own transforms to get that image ready for social/SEO use.

My guess is something is incorrectly setup in the Content SEO settings for whatever section the entry you're currently editing exists in. If you still can't figure it out, I'd be curious to see screenshots of those settings...

Also, fwiw, Andrew does provide a very handy SEO Settings field that might be worth considering as a replacement to the setup you've got going on currently. As he mentions in the plugin README:

Modern SEO works best if it actually reflects what is on the page, visible to the user, so pulling from your page's content will work well in most cases.

So what I've done (and would recommend, though it would mean you would lose your client-friendly field descriptions) is to pull the SEO/social data out of the content of the page and then add the SEO Settings field to that last tab just in case you need to overwrite stuff. For example, rather than adding the asset used as the masthead image and the asset used for SEO/social separately, use the same field for both. Makes it simpler on the client and on you! And then, if and when you do need a different image for the social/SEO metadata, you can use the SEO Settings field.

  • 1
    Thanks for the help Jalen. I worked out it was an issue with my BASE_URL environment variable. However, I'm awarding your answer as it gives some really helpful tips on the SEO field which I have implemented.
    – Dan Lee
    Commented Dec 12, 2018 at 10:29
  • I'm almost there... do you have time to answer a few questions regarding image varients in image optimize?
    – Dan Lee
    Commented Dec 12, 2018 at 11:33
  • Yeah I’d be happy to! You can either drop them here in the comments or create a new SE question for them if you like and I’ll give them a shot either way (prob easier to do a new question because I won’t have a character limit on my reply but I’ll leave it up to you)...
    – Jalen Davenport
    Commented Dec 12, 2018 at 11:39
  • Ok or would you prefere Slack Craft Group?
    – Dan Lee
    Commented Dec 12, 2018 at 11:40
  • That works as well. You can send me a DM...
    – Jalen Davenport
    Commented Dec 12, 2018 at 11:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.