← Guides
Links like /root_url or "javascript void(0)" in your Shopify theme
· 2 min read · Team BugRadar
Now and then we find a link whose address isn't an address at all: yourstore.com/root_url, yourstore.com/javascript void(0), or a bare #. Clicking it opens "Page not found" or does nothing.
Why it happens
- Someone edited the theme code and typed the name of a setting (root_url) as text, instead of using it to produce the real address.
- A button that should run a script was written as "javascript void(0)" without its colon, so the browser treats it as a page on your store.
- A theme section was added with its sample link still in place.
How to fix it
- Find the link on your live store and note the text around it (for example the footer heading it sits under).
- In your Shopify admin, go to Online Store and click Edit theme, open that section and set the link to a real page or collection.
- If the link isn't in the theme editor, it's in the theme code: ask whoever last edited your theme to fix it.
Check every link on your homepage after any theme edit or new app install. That's when placeholder links usually appear.
Catch it automatically
BugRadar's Pro plan checks the links beyond your menus every day: the announcement bar, homepage sections and footer icons. Pro comes with a 14-day free trial.
More guides
- Why Shopify menu links break, and how to catch them before shoppers do
- The footer bug that sends shoppers to "Page not found" instead of Instagram
- When a missing product shows your homepage: Shopify soft 404s
- Your refund or shipping policy link opens "Page not found": the fix
- How to find broken links on your Shopify store (free)
- What to check after you publish a new Shopify theme
- How to check your Shopify store on mobile (the 5 things that break)