We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more

How can I fix a duplicate content issue with index.html and index.php?

How can I fix a duplicate content issue with index.html and index.php?

kobra661116
Visitor
3 0 0

Hello, I did a seo audit, and i got such an error: littlewhite.com.pl/index.php - littlewhite.com.pl littlewhite.com.pl/index.html -littlewhite.com.pl The index.php or index.html document is as the home page of the website, which is located in the main domain and there it should redirect an inquiry like www.littlewhite.com.pl/index. If this is not the case and we can call such an adress on your site, it means that we deal with a copy of rhe content and add value to the site in the workplace. Such an error will be correct in the optimizatiob process, can You help me with this problem ?

Replies 3 (3)

frankymartin
Shopify Partner
33 0 22

Hi, same issue. Any help?

RushiJoshi
Shopify Partner
1 0 0

Facing similar issue, for index.html if we are going to Online Store --> Navigation --> URL Redirect, This way is also not working. Any Solution for the same?

 

CRHS
Tourist
3 0 1

add this code: "<script>
if (window.location.pathname === "/index.html") {
window.location.replace("/");
}
</script> " right before </head> in your theme.liquid