How to remove collection page in URL of each products

Solved

How to remove collection page in URL of each products

MsMarj
Excursionist
28 0 2

I want to avoid cannibalism in our site or canonical issues

 

I want to fix our product page URL to this

https://www.domain.com/products/boost-light-electric-height-adjustable-single-sided-workstation 

 

instead of this

 

https://www.domain.com/collections/height-adjustable-standing-desks/products/boost-light-electric-height-adjustable-single-sided-workstation 

 

And is it correct Google should indexed this kind of URL Structure?
https://www.domain.com/products/boost-light-electric-height-adjustable-single-sided-workstation 

Accepted Solutions (2)
Dan-From-Ryviu
Shopify Partner
8519 1677 1688

This is an accepted solution.

Hi @MsMarj 

Please check and remove that part in product-grid-item.liquid file. 

- Helpful? Like and Accept solution to let me know or Buy me Coffee ❤️!
- Ryviu - Product Reviews app, collect product reviews, import reviews from AliExpress, Amazon, Etsy, Shopee and Walmart and CSV.
- Lookfy app: Easy and fast to create Photo Gallery, Lookbook, Shop The Look.
- Enjoy 1 month of Shopify for $1. Sign up now.

View solution in original post

Dan-From-Ryviu
Shopify Partner
8519 1677 1688

This is an accepted solution.

Find this part and remove from your file 

| within: collection

- Helpful? Like and Accept solution to let me know or Buy me Coffee ❤️!
- Ryviu - Product Reviews app, collect product reviews, import reviews from AliExpress, Amazon, Etsy, Shopee and Walmart and CSV.
- Lookfy app: Easy and fast to create Photo Gallery, Lookbook, Shop The Look.
- Enjoy 1 month of Shopify for $1. Sign up now.

View solution in original post

Replies 13 (13)

Dan-From-Ryviu
Shopify Partner
8519 1677 1688

Hi @MsMarj 

You can remove it from the URL only when visitors open products from collection pages by deleting this part in "| within: collection" in collection liquid file.

If they open directly within the collection in the URL, then they cannot be removed. 

- Helpful? Like and Accept solution to let me know or Buy me Coffee ❤️!
- Ryviu - Product Reviews app, collect product reviews, import reviews from AliExpress, Amazon, Etsy, Shopee and Walmart and CSV.
- Lookfy app: Easy and fast to create Photo Gallery, Lookbook, Shop The Look.
- Enjoy 1 month of Shopify for $1. Sign up now.

MsMarj
Excursionist
28 0 2

Hi @Dan-From-Ryviu 

I check on my backend I don't have this collection liquid file

Dan-From-Ryviu
Shopify Partner
8519 1677 1688

Would you share your store URL to check?

- Helpful? Like and Accept solution to let me know or Buy me Coffee ❤️!
- Ryviu - Product Reviews app, collect product reviews, import reviews from AliExpress, Amazon, Etsy, Shopee and Walmart and CSV.
- Lookfy app: Easy and fast to create Photo Gallery, Lookbook, Shop The Look.
- Enjoy 1 month of Shopify for $1. Sign up now.

MsMarj
Excursionist
28 0 2
Dan-From-Ryviu
Shopify Partner
8519 1677 1688

This is an accepted solution.

Hi @MsMarj 

Please check and remove that part in product-grid-item.liquid file. 

- Helpful? Like and Accept solution to let me know or Buy me Coffee ❤️!
- Ryviu - Product Reviews app, collect product reviews, import reviews from AliExpress, Amazon, Etsy, Shopee and Walmart and CSV.
- Lookfy app: Easy and fast to create Photo Gallery, Lookbook, Shop The Look.
- Enjoy 1 month of Shopify for $1. Sign up now.

MsMarj
Excursionist
28 0 2

what specific code will I remove on product-grid-item.liquid ?

Dan-From-Ryviu
Shopify Partner
8519 1677 1688

This is an accepted solution.

Find this part and remove from your file 

| within: collection

- Helpful? Like and Accept solution to let me know or Buy me Coffee ❤️!
- Ryviu - Product Reviews app, collect product reviews, import reviews from AliExpress, Amazon, Etsy, Shopee and Walmart and CSV.
- Lookfy app: Easy and fast to create Photo Gallery, Lookbook, Shop The Look.
- Enjoy 1 month of Shopify for $1. Sign up now.

MsMarj
Excursionist
28 0 2

All good now @Dan-From-Ryviu Thank you so much

Dan-From-Ryviu
Shopify Partner
8519 1677 1688

You are very welcome! 

- Helpful? Like and Accept solution to let me know or Buy me Coffee ❤️!
- Ryviu - Product Reviews app, collect product reviews, import reviews from AliExpress, Amazon, Etsy, Shopee and Walmart and CSV.
- Lookfy app: Easy and fast to create Photo Gallery, Lookbook, Shop The Look.
- Enjoy 1 month of Shopify for $1. Sign up now.

EBOOST
Shopify Partner
1042 279 315

Hi @MsMarj ,

May I suggest to update  it  these steps:

1. Go to Store Online-> theme -> edit code

EBOOST_1-1672356985580.png

2. snippets/card-product.liquid

3. Remove "| within: collection" 

- Hope can help. If you find my reply helpful, please hit Like and Mark as Solution
- Need a Shopify developer? Contact email: eboost10@gmail.com
- Visit our site: https://www.eboosttech.net to view and download shopify themes and magento2 extensions free
- ❤❤DONATE ❤❤
MsMarj
Excursionist
28 0 2

Hi @EBOOST appreciate your response. I check on my end we don't have this snippets/card-product.liquid

pwcsangeeta
Shopify Partner
44 4 9

Hello @MsMarj 

Welcome to Shopify Community

To remove collection title from your URL you need to go 

Online Store----------------->Themes--------->Edit Code-------->Find file "card-product.liquid" Press ctrl+f and search "| within: collection"and remove that..your problem will resolved.

Please let me known if you have any question .

Thanks

MsMarj
Excursionist
28 0 2

Hi @pwcsangeeta 

Thank for taking time to response. 

 

On my end I don't have this card-product.liquid