Why isn't my cart page updating without a refresh?

Topic summary

A user experienced cart updates not reflecting immediately without page refreshes across multiple browsers (Chrome, Opera, Safari), though Firefox worked correctly.

Troubleshooting findings:

  • The issue resolved when disabling cache in Chrome DevTools network tab
  • This pointed to a cache-related problem
  • Previous attempts to add HTML code in theme.liquid to prevent caching were unsuccessful

Resolution:

  • BSS-Commerce support identified a prefetch link in the theme files causing the caching behavior
  • They recommended removing a specific line of code:
<link rel="prefetch" as="document" href="{{url}}">

from either the theme.liquid or meta-tags.liquid file

  • After implementing this change, the problem was resolved
Summarized with AI on November 19. AI used: claude-sonnet-4-5-20250929.

I have recorded my issue on video, please watch the attached video.

When I add a product to the cart, it is usually not added until I refresh the page. Or if I want to remove an item from the cart, the changes don’t appear until I refresh the page.

While investigating the problem, I realized something: this problem doesn’t happen in Firefox browser. The problem persists in browsers like google chrome, opera and safari.

Also, when I open the developer tools tab in google chrome, the problem is solved when I activate the “Disable cache” option in the network tab. So the problem might be cache related. But the html codes I added to the theme.liquid file to prevent caching did not work.

Thank you for your support.

Hi @brky
Can you kindly share your store link (with the password, if any) with us? We will check it and suggest you a solution if possible.

1 Like

Thank you for your reply. I sent you a private message.

Since I’m not familiar with the structure of your theme, I can only suggest that you look for a similar line of code in the theme.liquid or meta-tags.liquid file and remove it:

<link rel="prefetch" as="document" href="{{url}}">
1 Like

Problem solved, thank you very much.