Price Multiplier Not Tied to Product Quantity

Hi all! I’m setting up my first Shopify site and it’s coming along well, but I ran into a major snag and am really hoping someone can offer some advice for fixing it. The issue I’m having is on this page:

https://signsandbrandingproducts.com/products/flat-cut-acrylic-sign-letters

Let me explain. I have a sign letters product where users can enter the text they want, and then choose the material, color, thickness, and height of their text. The cost adjusts based on the height and thickness variants of the letters, but I also need the price to change based on the number of letters typed into the “Letters, Numbers, & Symbols” field. However, I can’t find an effective way to do this.

I tried just tying the products quantity to the # of characters in this field, but that doesn’t work because users can adjust the quantity on the checkout page without having the price adjust accordingly. In other words, they can reduce the price for their order of 10 letters down to the cost of 1 letter by adjusting the quantity at checkout, without reducing their specified letter count.

Anyone run into this issue? I have found another website where this works correctly, but don’t know how they got it working. https://www.woodlandmanufacturing.com/acrylic-letters.html

Thanks for your help!

-Dustin.

Hi @DustinA

Hope you’re doing good.
The requirement can be done with custom coding
you can see this for your information
www.stiled.com
this is custom calculation too

Hi @DustinA ,

Dustin, your issue is a common challenge for custom-priced products on Shopify. Since you need the price to dynamically adjust based on the number of letters entered (not just the quantity field), here are some possible solutions:

Solution 1: Use a Shopify App for Custom Pricing

Apps like “Dynamic Product Options” or “Infinite Options” can help you set up conditional pricing. These allow price calculations based on user input (like letter count) and prevent checkout quantity manipulation.

Solution 2: Use Shopify Script (Shopify Plus)

If you’re on Shopify Plus, you can use Shopify Scripts to modify cart behavior, ensuring the price adjusts correctly and that the customer can’t change the quantity manually.

Solution 3: Use Line Item Properties with JavaScript Validation

Since you’re using the King Product Options & Variant app, check if it allows dynamic price calculation based on character count. If not, you can manually implement it:

  1. Capture User Input in Line Item Properties

    • Modify your product page form to store the letter count in line item properties.
    <input type="text" name="properties[Custom Text]" id="customTextInput">
    
  2. Calculate Price in JavaScript (Frontend)

    • Use JavaScript to count the characters and adjust the price before adding to the cart.
    document.getElementById("customTextInput").addEventListener("input", function() {
        let text = this.value;
        let basePrice = 10; // Example base price per letter
        let price = basePrice * text.length;
        document.getElementById("product-price").innerText = "$" + price;
    });
    
  3. Disable Quantity Edits on Checkout

    • Hide or lock the quantity selector in the cart using Shopify’s cart attributes.
    • Add this in cart.liquid:
    <input type="hidden" name="updates[{{ item.key }}]" value="{{ item.quantity }}" />
    

Solution 4: Use a Custom Shopify App

If you need a fully custom pricing logic like Woodland Manufacturing, a Shopify App using Shopify Functions can be developed to calculate pricing dynamically based on text input.

1 Like

Thanks for the very fast and detailed reply! I’m sure one of these will work, but I’ll loop back if not.

Much obliged!

-Dustin.