When running an online store, measures that boost customers' purchasing motivation are essential. One of the most representative methods is "discounting."
An important point when running a discount campaign is displaying the "discount rate." A discount rate is extremely appealing information for customers and directly leads to increased sales. For example, when a specific number like "30% OFF" is shown, customers can immediately see how much of a deal they're getting. This lowers the psychological barrier to purchasing and can also encourage impulse buying.
Unfortunately, however, Shopify's default features don't include a way to directly display a product's discount rate.
This article explains in detail how to display discount rates on Shopify. Use it as a reference to maximize your customers' purchasing motivation.
Please note that this article includes instructions for editing code. Editing code can potentially break your store's design or cause products to display incorrectly. If you lack sufficient knowledge of code and feel uneasy about editing it, we strongly recommend consulting a professional.
Shopify's Standard Features Don't Display Discount Rates | Can Be Addressed with Code
When you sell a product at a discounted price on Shopify, both the regular price and the discounted price are displayed, clearly communicating to customers that a discount is being applied. At this point, a "Sale" label is shown, but the standard feature does not include the ability to display a specific discount rate such as "XX% OFF."

Displaying the discount rate strongly emphasizes the value to customers and can lead to increased sales. This feature can be achieved by writing programming code. The following sections explain the specific code with accompanying images.
If you don't have coding knowledge, you can safely and reliably implement discount rate display by consulting a professional with extensive code-editing experience, such as a "Shopify Partner" with Shopify development skills.
Preparation for Displaying Discount Rates on Shopify
To display a product's discount rate, you need to set both the discounted selling price and the pre-discount price. This can be configured on the Shopify product page.
Open the product page of the item you want to sell at a discount and scroll down to the pricing section. Enter the discounted selling price in "Price" and the pre-discount price in "Compare-at price."

Image source: Shopify admin
That's all the preparation needed.
In the image above, the original price is ¥14,000 and the discounted price is ¥7,000, which comes out to 50% OFF. Let's take a look at the actual screen.

Looking at the shoes in the middle, ¥14,000 is shown with a strikethrough, and the price is displayed as ¥7,000. Since the discount rate isn't shown yet, let's make it so "50% OFF" is displayed as well.
How to Display Discount Rates on Shopify with Code
Here's the code for displaying discount rates on Shopify. The theme used here is the official free theme "Dawn," version 15.3.0. Please note that if you're using a different version of the Dawn theme or a different theme altogether, the location where you need to add the code may differ.
Also, showing the discount rate is especially effective on a collection page where various products are listed side by side. This article introduces how to display it on a collection page, but if you'd like to display it in other sections or on product pages, please adapt the content accordingly.
Where to Edit the Code
From the Shopify admin, select Online Store. Click the "…" (ellipsis) next to the theme you want to edit, and select "Edit code."

Image source: Shopify admin
Before editing the code, always make a backup just in case. Click "…" (ellipsis) and select "Duplicate" to create a backup.
Once the code editor is open, select "snippets" from the menu, then select "card-product.liquid."

The code will appear on the right side of the screen; this is what you'll be editing.
Where to Add the Code and Its Content
In this example, the discount rate will be displayed below the price of each product shown in the collection.
The code should be inserted right after "{%- endif -%}" on line 288 and before "</div>" on line 289.
*Please note that if you're using a different theme version or a different theme, the insertion point may differ.

Press "Enter" after "{%- endif -%}" on line 288 to create a new line.

Paste the following code into the new line 289.
{%- comment -%}
Discount rate display code
{%- endcomment -%}
{%- liquid
assign compare_at_price = card_product.compare_at_price
assign price = card_product.price
if compare_at_price > price and card_product.available
assign sale_percentage = compare_at_price | minus: price | times: 100.0 | divided_by: compare_at_price | round
echo '<span class="sale-badge">' | append: sale_percentage | append: '% OFF</span>'
endif
-%}
{%- style -%}
.sale-badge {
display: inline-block;
padding: 0.25rem 1.2rem;
font-size: 1.2rem;
font-weight: 500;
line-height: 1.2;
color: #FFFFFF !important;
background-color: #D93A46;
border-radius: 9999px;
text-align: center;
}
{%- endstyle -%}

After pasting, click "Save" in the top right, then click "Preview store" to check the result on the actual screen.

Looking at the collection, the discount rate is now displayed below the price of the shoes.

If you want to change the color to match your site's theme color, edit the color codes in the code. A color code is a 6-digit alphanumeric string following the "#" symbol.
- color: Specifies the text color
- background-color: Specifies the background color
For example, changing the code as shown below will make the text red and the background yellow.
color: #FF0000 !important;
background-color: #FFFF00;

You can also change the label's appearance using CSS in other ways. That concludes this explanation.
"RuffRuff Order Bonus" Is Recommended for Running Discount Campaigns
Shopify lets you sell at a discounted price, display a "Sale" label, and issue coupons, but the standard features don't support discount campaigns beyond that.
So if you want to run discount campaigns that boost customers' purchasing motivation, we recommend "RuffRuff Order Bonus."
RuffRuff Order Bonus lets you implement all kinds of discount campaigns, including "volume discounts," "discounts based on subtotal amount," "VIP member-only discounts," and "limited-time sales." It can be set up with simple operations, without editing any code, so even those without programming knowledge can use it. The settings screen is also available in Japanese, and Japanese-language customer support is available, so beginners can use it with peace of mind.
The app is available from US$9.90/month, with a 3-day free trial. If you're considering a discount campaign, please give it a try. Pricing varies by Shopify plan (as of November 2, 2026).
Display Discount Rates on Shopify to Boost Your Customers' Purchasing Motivation
This article explained how to display discount rates for products in a Shopify store's collection.
Shopify's standard features don't include a way to display discount rates, but this can be addressed by adding programming code. Displaying "XX% OFF" on a product strongly conveys value to customers and can be expected to boost their purchasing motivation.
If you're not confident editing code, consult a professional. By working with a Shopify Partner or an experienced freelance developer, you can implement discount rate display safely and reliably, without negatively affecting your store's design or functionality.
Display discount rates to boost your customers' purchasing motivation and increase your sales.
Finally, the blog article below introduces how to set up sales on Shopify and specific sales campaign ideas. Please use it as a reference.
