Magento 2 thumbnail main image cache path link changed from this link on the home page after 2 days pub/media/catalog/product/cache/be293bf7411b924394287949fb9084eb/b/e/be-in-in.png

to this


because of that, I am getting this

but when do flush Magento cache it changes back to


please can anyone give me suggestion to solve this issue?



You need to create a custom module to be able to change the image path

Create that Block class and extend \Magento\Framework\Data\Form\Element\Image

namespace VendorName\ModuleName\Helper\Image;

class Custom extends \Magento\Framework\Data\Form\Element\Image

    public function _getUrl()
        $url = 'YourModulePath'.$this->getValue(); 
        return $url;
  • but i am not getting any issue on beta site this only happens after 2 or 3 days the image path is changed automatically Jun 7 at 7:38
  • and this issue is only occur on home page all other page is getting the image Jun 7 at 7:39
  • The path containing the image is a fixed URL and it will not change unless you intervene and these links. You can check that the extensions you are using and especially the theme you are using are calling the correct image link. Jun 10 at 2:21
  • the issue is images are not visible only on the homepage but visible on all frontend pages Jun 21 at 7:26
  • Have you deployed and re-run the indexer for your site? If not, please run the commands one by one: php bin/magento setup:static-content:deploy php bin/magento indexer:reindex Jul 1 at 6:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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