Rewrites active-product variant prices to end in a charm value (default .99) while keeping the whole-dollar part, skipping prices already at the ending and below 1.00.
async def run(ctx): ending = ctx.params.get("ending", 0.99) for variant in await ctx.shopify.query(ALL_VARIANTS):
How do you apply charm pricing across a Shopify catalog?
To apply charm pricing across a Shopify catalog, this template rewrites each active variant price to end in your charm value, .99 by default, while keeping the whole-dollar part. A price of 24.50 becomes 24.99, a price already at 24.99 stays untouched, and anything below 1.00 is skipped so accessories and samples keep their pricing. Compare-at prices are left alone, so sale visuals survive the pass. The ending is configurable: .95, .90 and .00 stores exist, and the template takes whichever convention you run.
One run aligns thousands of variants with the pricing psychology you decided on. Done by hand this is the classic spreadsheet night, and one mistyped column breaks prices with no undo. As code, the rounding produces a before-and-after list for every variant it would touch; you scan it for surprises, then let it write.
Last updated August 24, 2026
If you run a sharper version of this template, or something it inspired, send it in. We review every application and publish the good ones, credited to you or your agency.
AI writes real Python or TypeScript, a dry run rehearses it, you approve, it deploys.
Free plan · no card · 🇪🇺 EU data residency