Why a 3.0x ROAS Can Still Lose Money on Cyber Week (Break-Even ROAS Math in Pure JS)

2026-11-28来源 dev.toEnglish

During Black Friday and Cyber Week, ad dashboards love to celebrate a 3.0x ROAS. On paper, spending $100 to bring in $300 in gross sales sounds profitable.

In practice, many Shopify, Amazon, Etsy, and DTC sellers lose money at 3.0x ROAS because ad platforms calculate ROAS against gross order price, while your bank account pays out net contribution after VAT/GST, platform fees, payment processing, COGS, shipping, packaging, and returns.

Here is the exact math — implemented as pure, zero-dependency JavaScript functions — so you can compute break-even ROAS, break-even CPA, and target ROAS for any SKU or CSV catalog before scaling ad spend.

1. The Worked Example: Why 3.0x ROAS Can Be Underwater

Suppose you sell a $49 product during Cyber Week (tax-inclusive pricing with 10% VAT):

Line Item Formula / Value Amount
Selling Price (gross) $49.00 $49.00
VAT included (10%) 49 - 49 / 1.10 -$4.45
Net Revenue 49.00 - 4.45 $44.55
COGS + Shipping + Packaging $14.00 + $6.50 + $1.50 -$22.00
Platform + Payment Fees (2.9% + $0.30, + 2% app/channel) 49 * 0.049 + 0.30 -$2.70
Returns Allowance (6% of gross) 49 * 0.06 -$2.94
Contribution Before Ads 44.55 - 22.00 - 2.70 - 2.94 $16.91

Now compute your ad thresholds:

  • Break-even CPA: $16.91 (spend $1 more per order and you lose money)
  • Break-even ROAS: $49.00 / $16.91 = 2.90x
  • Target ROAS for a 15% net margin (15% × $44.55 = $6.68 target profit per order):
    • Allowable ad spend = $16.91 - $6.68 = $10.23
    • Target ROAS = $49.00 / $10.23 = 4.79x

Now drop the price 15% for a Cyber Week promo ($41.65) while COGS and shipping stay fixed at $22.00:

  • Net revenue after 10% VAT: $37.86
  • Fees + 6% returns allowance: $4.84
  • Contribution before ads: $37.86 - $22.00 - $4.84 = $11.02
  • New Break-even ROAS: $41.65 / $11.02 = 3.78x

A 3.0x ROAS on that 15%-off Cyber Week promo loses $2.86 on every single order.

2. Pure JS Implementation (Zero Dependencies)

Keeping the calculation layer pure makes it reusable across browser apps, Node scripts, and bulk SKU CSV pipelines:

/** * Compute per-order profit, break-even ROAS/CPA, and target ROAS. * All percentage inputs are passed as decimals (e.g. 0.10 for 10%). */ export function calcOrderMetrics({ price, vatRate = 0, cogs = 0, shipping = 0, packaging = 0, otherCost = 0, platformPct = 0, platformFixed = 0, paymentPct = 0.029, paymentFixed = 0.30, returnRate = 0, adCostPerOrder = 0, targetMargin = 0.15, }) { const vatAmount = vatRate > 0 ? price - price / (1 + vatRate) : 0; const netRevenue = price - vatAmount; const platformFee = price * platformPct + platformFixed; const paymentFee = price * paymentPct + paymentFixed; const totalFees = platformFee + paymentFee; const productCost = cogs + shipping + packaging + otherCost; const returnsAllowance = price * returnRate; // Profit before ad spend (contribution margin in currency) const contribution = netRevenue - productCost - totalFees - returnsAllowance; const netProfit = contribution - adCostPerOrder; const breakEvenROAS = contribution > 0 ? price / contribution : Infinity; const breakEvenCPA = Math.max(0, contribution); const breakEvenACoS = contribution > 0 ? contribution / price : 0; const targetProfit = targetMargin * netRevenue; const allowableAdSpend = contribution - targetProfit; const targetROAS = allowableAdSpend > 0 ? price / allowableAdSpend : Infinity; return { netRevenue, totalFees, returnsAllowance, contribution, netProfit, netMarginPct: netRevenue > 0 ? (netProfit / netRevenue) * 100 : 0, breakEvenROAS, breakEvenCPA, breakEvenACoS: breakEvenACoS * 100, targetROAS, }; } 

Modeling Ad Spend Scenarios Across ROAS Tiers

Once you have contribution, evaluating a campaign budget across a grid of ROAS scenarios takes two lines:

export function simulateBudgetScenarios(budget, price, contribution, roasList = [2, 2.5, 3, 3.5, 4, 5]) { return roasList.map((roas) => { const grossRevenue = budget * roas; const orders = price > 0 ? grossRevenue / price : 0; const profit = orders * contribution - budget; return { roas, orders: Number(orders.toFixed(1)), grossRevenue: Number(grossRevenue.toFixed(2)), cpa: orders > 0 ? Number((budget / orders).toFixed(2)) : Infinity, profit: Number(profit.toFixed(2)), roiPct: budget > 0 ? Number(((profit / budget) * 100).toFixed(1)) : 0, }; }); } 

3. Two Gotchas When Exporting Bulk SKU Reports to Excel

If you let sellers upload a CSV of 500 SKUs and export a profit audit back to CSV, two small details prevent real-world headaches:

  1. Prepend a UTF-8 BOM (\uFEFF) so Excel on Windows renders currency symbols (€, £, ₩, ¥) and non-ASCII SKU names cleanly instead of mojibake.
  2. Neutralize CSV formula injection on untrusted SKU titles or notes: any cell starting with =, +, -, @, \t, or \r should be prefixed with a single quote (') before quoting.
export function safeCsvCell(value) { const raw = String(value ?? ""); const neutralized = /^[=+\-@\t\r]/.test(raw) ? `'${raw}` : raw; return /[",\r\n]/.test(neutralized) ? `"${neutralized.replace(/"/g, '""')}"` : neutralized; } 

Try It Live (Zero Login, Runs 100% Client-Side)

I packaged these formulas — along with presets for Shopify, Amazon, Etsy, eBay, TikTok Shop, Naver SmartStore, and Coupang, EN/KO switching, multi-currency formatting, ad-spend scenario tables, and bulk SKU CSV auditing — into an open-source, zero-dependency static web app:

If you run ads on multiple marketplaces, what hidden fee catches your margin off guard most often — return rates, FBA/fulfillment surcharges, or promo stacking?

原文:https://www.a8q9.cn/en/article/why-a-3-0x-roas-can-still-lose-money-on-cyber-week-break-even-roas-math-in-pure--0ed24c.html

相关文章