Imgix and CORS

Hello,

When requesting images from imgix (through https://www.datocms-assets.com) the ‘Access-Control-Allow-Origin’ header is bound to a specific domain, instead of “*”. This causes issues when deploying our site on multiple domains (for staging, production, etc).

The imgix documentation states that it is possible to change the CORS settings for such use cases in the imgix dashboard (https://support.imgix.com/hc/en-us/articles/360000537526-Cross-Domain-policy). How can we update these settings for our website ?

Thanks in advance for any support,
Alexandre

Hello @it and welcome to Community!

Thank you for the suggestion, I’ve changed that setting in our Imgix account. Please let me know if you still have any issue with that.

Hi @mat_jack1,
seems I have similar issue. Could you please change ‘Access-Control-Allow-Origin’ header for me too?
Thanks

hello @yuri welcome! :slight_smile:

we didn’t change anything in the end, it was working. Can you please share a broken example? So that we can have a look?

Thanks

hi @it and @yuri , please try again now but clear your browser cache first! Let us known :slight_smile:

Now it works like a charm. Thanks!

2 Likes