All Collections
Developer
How to get Rebuy JS to load as fast as possible
How to get Rebuy JS to load as fast as possible

Learn how to speed up Rebuy Smart Cart, Widgets, etc on your Store!

Strauss Van Wagenen avatar
Written by Strauss Van Wagenen
Updated over a week ago

Improve Rebuy load speed

By default Shopify loads all apps after the regular Shopify site has finished loading. This means Rebuy is not allowed to run until after the site has finished loading which can sometimes take 3-4 seconds or longer to load features such as Smart Cart, Widgets, etc.. We can change this by the adding Rebuy JS directly to your theme.


Within the Rebuy admin, you can navigate to "account" > "settings."

Next, all you need to do is click "install!"

Once you do this, your screen will update, and the settings will be inserted directly into your theme. You will know this has successfully been inserted into your theme when you see that Rebuy JS has is set to 'no' on this page.




The second option you have is to manually inserting this into your theme.

In your theme's theme.liquid file, add the following script tag before the closing body tag:

<script async src="https://cdn.rebuyengine.com/onsite/js/rebuy.js?shop={{ shop.permanent_domain }}"></script>

Then, remember to turn off Rebuy JS via your settings here: https://rebuyengine.com/settings. Switch "Enable Rebuy JS" from "Yes to "No" and save.

Did this answer your question?