How to increase the quantity using decimal numbers

Topic summary

Core Issue:
A user wants to enable decimal quantity inputs (0.1, 0.2, 0.3) for product orders, specifically for products using the default template. They shared Liquid code showing their current integer-based quantity input setup.

Key Response:
Shopify natively does not support decimal quantities in the quantity input field, as confirmed by official documentation.

Workaround Suggested:
One contributor mentioned fabric stores use a common workaround where the smallest fraction becomes one unit. For example, ordering 1.5 translates to a quantity of 3 (where each unit represents a half). This approach manipulates quantities behind the scenes to achieve decimal-like ordering while maintaining integer inputs.

Current Status:
Another user expressed similar needs for decimal quantities. Multiple participants offered implementation assistance, but no concrete solution or code modification was provided in the thread. The discussion remains open with the workaround as the primary alternative approach.

Summarized with AI on November 4. AI used: claude-sonnet-4-5-20250929.

Hey there,

I would like to increase the quantity for ordering using decimal numbers (0.1, 0.2, 0.3…), not integers. That would apply only for products that use a default template (in the code below it’s the first IF condition).
I hope you can give me a hand.
Regards,
Renko

{%- if template.suffix == nil -%}

{{ 'products.product.quantity.decrease' | t: product: product.title | escape }} {% render 'icon-minus' %} {{ 'products.product.quantity.increase' | t: product: product.title | escape }} {% render 'icon-plus' %} {%- else -%} {{ 'products.product.quantity.decrease' | t: product: product.title | escape }} {% render 'icon-minus' %} {{ 'products.product.quantity.increase' | t: product: product.title | escape }} {% render 'icon-plus' %} {%- endif -%}

Hi @Renko2022 ,

Shopify does not support you entering Quantity as Decimal Numbers. Refer https://shopify.dev/themes/architecture/templates/product#the-quantity-input

So this is not possible.

Hope it is clear to you.

1 Like

Hi @Renko2022 ,

I saw you liked my answer. If it helped you solve your issue, please mark it as a solution. Thank you and good luck.

1 Like

Hi,

Did we resolve this issue of getting quantity in Decimal Numbers as this is what i needs also.

Please do let me know how can that be done?

Thanks,

Amar

While Shopify does not support decimal order quantities, there is a workaround which is being used by most fabric stores. For example

https://fabrics-fabrics.com/

The way it works is that the lowest fraction is considered a unit and quantities are manipulated for ordering the correct number. So 1.5 becomes 3 quantity of half unit.

how is it done? by app?

is this something that you helped implement? if so, we may need your services

1 Like

I can do it for you

aatif6325@gmail.com