How to change the text color of the sale badge?

How to change the text color of the sale badge?

myl1
Excursionist
36 0 2

Hi hi, 

 

I would love to change the text color of the sale badge, but I can't find how to do this. Can someone help me? As you can see it's white now and it has to be black because people can't read it now 😞 

 

Thanks in advance! 

 

Scherm­afbeelding 2024-09-10 om 11.13.33.png

Replies 11 (11)

dws_pvt_ltd
Shopify Partner
329 65 91

Hello @myl1

Please share your store URL and password.So that I will check and let you know the exact solution here.


Feel free to reach out if you have any questions or need assistance.
Best Regards,
DWS.

 

Helpful? then please Like and Accept the Solution.
For any inquiries, please feel free to contact via WhatsApp and Email: sales@dolphinwebsolution.com.
For more information visit our website Dolphin Web Solution Pvt Ltd.
myl1
Excursionist
36 0 2
Tech_Coding
Shopify Partner
287 72 64

Hello @myl1 

You can add code by following these steps

1. Go to Online Store -> Theme -> Edit code.
2. Open your theme.liquid file

3. Paste the below code before </body> on theme.liquid
<style>
   .badge--onsale {
      color: #000 !important;
   }
</style>

Tech_Coding_0-1725961047507.png

my reply helpful? Click Like to let me know!
your question answered? Mark it as an Accepted Solution.

my reply helpful? Click Like to let me know!
your question answered? Mark it as an Accepted Solution.
Shopify UI Developer
Your Coffee Tips adds a little sweetness to my day.
dws_pvt_ltd
Shopify Partner
329 65 91

Hello @myl1 

Step 1: Go to Shopify Admin -> Online Store ->Theme -> Edit code
Step 2: Search file base.css, theme.css, styles.css, custom.css or theme.scss.liquid
Step 3: Insert the below code at the bottom of the file -> Save

 

 

<style>
span.badge.badge--onsale {
    color: #000;
}
</style>

 

 

Output:-

dws_pvt_ltd_0-1725961114836.png

Best Regards,
DWS.

Helpful? then please Like and Accept the Solution.
For any inquiries, please feel free to contact via WhatsApp and Email: sales@dolphinwebsolution.com.
For more information visit our website Dolphin Web Solution Pvt Ltd.

AnneLuo
Shopify Partner
933 173 199

Hi, @myl1 

Can you please share the store URL so that I can assist you?

If this is helpful, please Like and Accept the solution.
Want to modify or custom changes on store? Let me help.
- Feel free to Email Me   

Buy Me A Coffee

myl1
Excursionist
36 0 2
AnneLuo
Shopify Partner
933 173 199

I have applied the access. Please accept.

If this is helpful, please Like and Accept the solution.
Want to modify or custom changes on store? Let me help.
- Feel free to Email Me   

Buy Me A Coffee

DaveedValencia
Shopify Partner
26 5 5

Add the following CSS but change the color from red to your desired color. 

.price__sale .price-item--regular {
  color:red;
}

 

BSSCommerce-HDL
Shopify Partner
2292 842 1057

Hi @myl1

Step 1: Go to Shopify Admin -> Online Store ->Theme -> Edit code

Step 2: Search file theme.liquid

Step 3: Insert this code above </head> tag:

 

<style>
.card__badge .badge.badge--onsale {
    color: black !important;
}
</style>

 

Here is result: 

BSSCommerceHDL_0-1725960972323.png

 

Hope this can help you,

If our suggestions are useful, please let us know by giving it a like or marking it as a solution. Thank you 😍

Sale banner, pop ups: Customize your sale banner, pop-ups and create countdown bar to boost conversion rate.
Simicart: Transform your Shopify store into a stunning and fully functional mobile app with just a few simple steps.
Product Labels & Badges:
Get more sales with striking labels, badges, and banners from our 10,000+ available templates.

BSS Commerce - Full-service eCommerce Agency | Use Shopify for 1$ in the first month now

PageFly-Richard
Shopify Partner
4661 1068 1725

Hi @myl1 

 

This is Richard from PageFly - Shopify Page Builder App

 

Please add this code to your theme.liquid above the </head> to get this solved

Step 1: Online Stores > Themes > More Actions > Edit code

Step 2: click on theme.liquid and paste the code above the </head>

<style>
 .badge--onsale {
      color: #000 !important;
   }
</style>

 

Hope this can help you solve the issue 

 

Best regards,

Richard | PageFly 

Please let me know if it works by giving it a Like or marking it as a solution!


➜ Optimize your Shopify store with PageFly Page Builder (Free plan available) 


All features are available from Free plan. Live Chat Support is available 24/7.

Amanda_Fordeer
Shopify Partner
110 8 29

@myl1 

Have you done this?

If not, you can consider using Product Labels&Badges to do that. 

 
If you find my suggestion helpful, please give it a like or mark it as a solution!
And discover more approaches to:
Streamline invoicing process Boost sales with labels & badges Add social proofs & create FOMO
Or get valuable updates and private deals regarding Shopify here.