All things Shopify and commerce
Hi guys,
I've tried several other solutions for this in this forum and elsewhere online but nothing has worked unfortunately.
I'm trying to change the sold out button and text colour, text to white and the button to red. It would need to be consistent across the homepage "featured collection" and the "product grid".
My website is gchem.co.uk
If somebody could help it would be very much appreciated.
Alex
Solved! Go to the solution
This is an accepted solution.
Hi @gchemuk
Check this one.
.card__badge.bottom.left .badge {
background: red;
padding: .6rem 1rem;
color: white;
}
Please don't forget to Like and Mark Solution to the post that helped you. Thanks!
This is an accepted solution.
You are talking about the product page? The product page have different code not same on the collections.
This is for the product page.
span.badge.price__badge-sale.color-background-2 {
color: white;
background: red;
padding: .6rem 1rem;
}
span.badge.price__badge-sold-out.color-background-1 {
color: black;
background: blue;
padding: .6rem 1rem;
}
AndSave.
The sale is background-2 and sold-out is background-1.
Please don't forget to Like and Mark Solution to the post that helped you. Thanks!
This is an accepted solution.
Hi @gchemuk
Check this one.
.card__badge.bottom.left .badge {
background: red;
padding: .6rem 1rem;
color: white;
}
Please don't forget to Like and Mark Solution to the post that helped you. Thanks!
Thanks alot!!
Sorry but I've realised that now both the sold out and sale badges are the same. Is there a way of having an individual colour for each?
Would you mind to provide the URL/products with sale badge?
The super sample wash kitt, it's red with **bleep**e text in the shop all section but within the product it's red with blue text. The sold out badge is also still white with blue text within the product pages.
PLease, replace the code wit this one. And add your desired color.
/* sold-out badge */
.badge.badge--bottom-left.color-background-1 {
color: black;
background: blue;
padding: .6rem 1rem;
}
/* sale badge */
.badge.badge--bottom-left.color-background-2 {
color: white;
background: red;
padding: .6rem 1rem;
}
And Save,.
Result:
Please don't forget to Like and Mark Solution to the post that helped you. Thanks!
This is an accepted solution.
You are talking about the product page? The product page have different code not same on the collections.
This is for the product page.
span.badge.price__badge-sale.color-background-2 {
color: white;
background: red;
padding: .6rem 1rem;
}
span.badge.price__badge-sold-out.color-background-1 {
color: black;
background: blue;
padding: .6rem 1rem;
}
AndSave.
The sale is background-2 and sold-out is background-1.
Please don't forget to Like and Mark Solution to the post that helped you. Thanks!
Thank you so much! 🙌
Learn how to build powerful custom workflows in Shopify Flow with expert guidance from ...
By Jacqui May 7, 2025Did You Know? May is named after Maia, the Roman goddess of growth and flourishing! ...
By JasonH May 2, 2025Discover opportunities to improve SEO with new guidance available from Shopify’s growth...
By Jacqui May 1, 2025