Learn how to Add sale badge on Products based on price on Shopify based on their price, follow these steps:
- Log In to Shopify Admin: Open your Shopify admin dashboard and log in to your account.
- Navigate to Products: From the left-hand menu, click on “Products” to access your product listings.
- Choose a Product: Select the product to which you want to add the “On Sale” badge.
- Edit Product: Once you’ve selected the product, click on the “Edit” button to make changes.
- Adjust Pricing: Scroll down to the “Pricing” section. This is where you can adjust the product’s pricing details.
- Compare at Price: Under the “Pricing” section, you’ll find an option called “Compare at price.” This is the original price of the product before the discount. Enter the original price here.
- Selling Price: Just below the “Compare at price” field, you’ll see the “Price” field. Enter the discounted selling price of the product here.
- Save Changes: After entering the original and discounted prices, scroll to the top or bottom of the page and click the “Save” button to save your changes.
- Products must have “Compare at price” field fill in admin.
- Shows Badge when “compare_at_price_max” > “product price”
-
{% if product.compare_at_price_max > product.price %} <img class="sale-product" src="{{ 'sale-badge.png' | asset_url }}" alt="On Sale Badge"> {% endif %}
- Apply “On Sale” Badge: Now, you need to apply the “On Sale” badge to products with a discounted price. Shopify usually does this automatically, but if it doesn’t, you can do it manually.
- Go back to the list of products.
- Click on the product you edited.
- In the “Online Store” section, check the box that says “Online Store.”
- Click on the “Manage” button next to “Tags.”
- Add a tag like “On Sale” or “Discounted.”
- Save your changes.
- Adjust Theme Settings (If Necessary): Depending on your Shopify theme, the “On Sale” badge might be automatically displayed when the “Compare at price” is set and the product is discounted. However, if it doesn’t appear automatically, you may need to adjust your theme settings or use an app to enable this feature.
- Preview and Publish: To ensure everything looks as expected, preview your product listing on your online store. If the “On Sale” badge is displayed correctly, you can go ahead and publish your changes.
Read More about Product Prices
Related Article How to add custom tags using product page on shopify?
Leave a Reply