COGS (cost of goods sold) is the direct cost of producing or acquiring the products you actually sold during a given period — the raw materials, the manufacturing, the per-unit packaging, the freight to get a finished item into your hands. It does not include rent, ads, your salary, or the software you run the business on. Those are operating costs. COGS is the narrow, specific number that answers one question: before you spent a single dollar trying to find a customer, what did the stuff itself cost you? Get this number right and almost every other financial decision — pricing, discounts, which products to keep — gets easier. Get it wrong, and you can sell like crazy and still go broke.
Why COGS (cost of goods sold) matters
Here is the uncomfortable truth most first-time founders learn too late: revenue is vanity, and COGS is where the real story lives. You can post a screenshot of a $40,000 sales month and still be losing money on every order, because the products inside those orders cost more to make and ship than you charged. COGS is the line that separates "I'm busy" from "I'm profitable." It's the input to your gross margin, and gross margin is the oxygen supply of a young company.
The numbers back this up in a brutal way. Across thousands of online stores, the average net profit margin lands around 10% even though gross margins look healthy on paper, according to Onramp Funds (2025). That gap — fat gross margin, thin net margin — is exactly where bad COGS math hides. And cash, not profit, is what actually kills companies. SCORE data cited by SMB Compass (2025) attributes 82% of small business failures to cash flow problems, and a huge share of those problems trace directly back to founders who priced products without truly knowing what each unit cost them.
It matters more in e-commerce than almost anywhere else because the category is enormous and competitive. Worldwide retail e-commerce sales reached roughly $6.42 trillion in 2025, accounting for more than 20% of total global retail, per eMarketer (2025). In a market that big and that crowded, your competitors have already squeezed their unit costs. If you don't know yours to the cent, you'll either price too high and lose the sale or price too low and lose the business. There's no comfortable middle for a founder who's guessing.
COGS is also the number your future self will care about most. The day you apply for inventory financing, talk to an accountant, or try to sell the business, the first thing anyone serious looks at is gross margin — which is built entirely on a clean COGS figure. Learning to track it properly from day one isn't bookkeeping busywork. It's the habit that makes you legible to lenders, partners, and yourself.
There's a cash-timing angle here that benchmarks rarely capture and that bites founders hardest in year one. You pay COGS up front — you wire the factory, pay the freight, and buy the packaging weeks or months before a customer ever checks out. Revenue comes later. That gap between spending on inventory and collecting from buyers is where new businesses suffocate, and it's why understanding COGS isn't only an accounting exercise but a survival one. A founder with a beautiful 60% gross margin can still run out of money if they sink every dollar into stock that sells slowly. Knowing your per-unit COGS lets you order the right quantity instead of over-buying inventory you can't afford to sit on, which is the difference between a tight quarter and a closed business.
How COGS (cost of goods sold) works
At its simplest, COGS is the cost of inventory that left your shelves and went to customers in a period. The classic accounting formula is straightforward:
- Start with beginning inventory — the cost value of the stock you had on hand at the start of the period.
- Add purchases — everything you bought or produced during the period to restock or build new units.
- Subtract ending inventory — the cost value of what's still sitting unsold when the period closes.
So: COGS = Beginning Inventory + Purchases − Ending Inventory. Whatever was in stock, plus whatever you added, minus whatever's left, equals what you sold. That's the bookkeeping view, and it's how COGS shows up on a profit-and-loss statement.
But as a founder making day-to-day decisions, you usually care about per-unit COGS — the all-in cost of a single finished product ready to ship. That's the number that tells you whether a sale makes sense. To build it, you add up every direct cost that touches one unit:
- The product itself — what you pay your supplier or manufacturer per piece, which often depends on hitting a minimum order quantity.
- Inbound freight and duties — the cost of moving goods from the factory to your warehouse or home, divided across the units in the shipment.
- Packaging — the box, the mailer, the tissue paper, the branded sticker, the dunnage. If it ships with the product, it's COGS.
- Direct labor or assembly — if someone is paid to hand-pour, hand-assemble, or kit the product, that per-unit labor counts.
- Per-transaction product costs — for some models, things like blank-garment cost in print-on-demand or the per-unit cost on a private-label run are essentially your entire COGS.
What stays out is just as important. Marketing, your customer acquisition cost, payment processing fees, software subscriptions, office rent, and your own pay are operating expenses, not COGS. They're real and they matter, but they live below the gross-margin line. Keeping that boundary clean is what lets you compare products fairly and spot which ones are actually worth selling.
One more mechanic trips people up: COGS only counts the cost of units that actually sold, not everything you bought. If Maya buys 500 vessels but only sells 200 candles this quarter, only the cost of those 200 vessels hits her COGS for the period. The other 300 sit in inventory on her balance sheet as an asset until they sell. This is why the beginning-plus-purchases-minus-ending formula exists — it's the accounting world's way of matching the cost of a product to the moment it earns revenue. For day-to-day pricing you'll lean on per-unit COGS, but when you file taxes or read a real P&L, that timing rule is the one to remember.
A note on inventory costing methods
When you've bought the same product at different prices over time, you need a rule for which cost to assign when a unit sells. Three are common. FIFO (first-in, first-out) assumes the oldest inventory sells first, so in a period of rising supplier prices it reports lower COGS and higher profit. LIFO (last-in, first-out) assumes the newest stock sells first, reporting higher COGS and lower taxable profit when costs rise — though it's restricted or disallowed in much of the world. Weighted average blends all your unit costs into one number and is the simplest to run. Most small e-commerce founders use FIFO or weighted average. You don't need to agonize over this on day one, but pick one method, write it down, and stay consistent — switching mid-stream makes your numbers impossible to compare and can raise eyebrows at tax time.
A real-feeling example
Say Maya runs a candle store. She sells a signature soy candle for $32 and her first instinct is "great, that's basically free money." Let's actually do the COGS math she should have done before launch.
Per candle, her direct costs look like this: soy wax and fragrance oil, $4.10; the glass vessel, $3.25; wick, lid, and warning label, $0.90; the branded box and tissue, $2.15; inbound freight from her vessel supplier spread across the order, $0.70; and 12 minutes of her contract pourer's time at roughly $1.40. Add it up and her per-unit COGS is $12.50. On a $32 candle, that's a gross profit of $19.50 per unit and a gross margin of about 61% — right in the healthy band for a self-produced brand.
So far, so good. But here's where Maya nearly fooled herself. When she only counted the wax, vessel, and wick — the "obvious" product cost of $8.25 — she thought her margin was 74% and happily ran a "buy two, get one free" promotion. Once you fold in packaging, freight, and labor, that promotion sold three candles for $64 against $37.50 of true COGS, leaving $26.50 of gross profit before she'd spent a cent on ads. Factor in a 17% return rate typical of online retail, and the promo was barely above breakeven. The lesson wasn't that promotions are bad. It was that a hidden $4.25 per unit of "non-obvious" COGS turned a fat-looking deal into a near-loss. Knowing her real number let her redesign the offer.
Now watch what happens when Maya uses that same number to make a smart decision instead of a costly one. She wants to advertise. With $19.50 of gross profit per candle, she knows she can spend up to roughly $19 to acquire a customer who buys one candle and still break even on that first order — and far less if she wants the first sale to be profitable on its own. A founder who thought their per-unit cost was $8.25 would believe they had $23.75 of room and overspend on ads chasing sales that quietly lose money. The exact same ad campaign is either disciplined or reckless depending entirely on whether the COGS feeding the math is honest. That's the whole game: COGS isn't a number you report after the fact, it's the number that tells you what every other move actually costs.
The formula, your margin, and where benchmarks fit
Once you have COGS, two numbers fall out of it that you'll use constantly. The first is gross profit: Selling Price − COGS. The second is gross margin: (Selling Price − COGS) ÷ Selling Price, expressed as a percentage. Margin is the one to internalize, because it's comparable across products and price points. A $12 product and a $120 product can have the exact same 60% margin, and that tells you something a raw dollar figure can't.
It helps to know what "good" looks like, but treat benchmarks as a compass, not a verdict. Gross margins swing hard by category. Beauty and supplements often run 65% and up, apparel tends to land in the 40–60% range, and electronics get squeezed down to 15–25%, according to Opensend (2025). Your business model matters too — the same data shows dropshipping stores often sit around 65–70% gross margin precisely because they hold no inventory, while private-label brands run a touch lower because they own production costs. If your margin is wildly off the benchmark for your niche, that's a signal to investigate, not necessarily a problem.
You don't get to keep your gross margin. You get to spend it. Every dollar of gross profit is the budget you have for ads, shipping, returns, salaries, and profit — and COGS decides how big that budget is before you've even opened the store.
This is why founders who obsess over the top-line price and ignore COGS get blindsided. Your markup and your profit margin are two sides of the same coin, both anchored to a cost number you control. Lower your COGS by 10% through better sourcing or smarter packaging, and you've effectively given yourself a raise on every single order, forever — without raising prices or spending a dollar more on marketing.
There's also a strategic reason to keep COGS in view as you grow: it interacts with every other lever in the business. When your average order value rises because you bundled products or added a higher-margin item, your blended COGS percentage usually improves. When you negotiate a better unit price by hitting a larger order quantity, COGS drops and margin climbs. And when you decide how aggressively you can spend to acquire a customer — how much you can pay for an ad click before a sale stops being worth it — the ceiling is set by the gross profit that COGS leaves behind. In that sense COGS isn't a back-office number at all. It's the constraint that quietly shapes your pricing, your promotions, your ad budget, and even which products earn a place in your catalog.
COGS vs operating expenses: where to draw the line
The single most common confusion for new founders is the boundary between COGS and operating expenses (often called OpEx or SG&A). The clean rule: if a cost rises and falls directly with how many units you make or buy, it's probably COGS. If a cost stays roughly the same whether you sell 10 units or 1,000, it's probably operating expense.
Your fragrance oil scales with production — that's COGS. Your monthly email tool costs the same regardless of volume — that's OpEx. Fulfillment gets murky: the per-order pick-and-pack and the outbound shipping label often live just below COGS as separate line items, while the warehouse's flat monthly storage fee is operating overhead. You don't have to be a CPA about it. You just have to be consistent, because consistency is what makes your numbers comparable month to month.
A practical way to keep the line clean is to ask, for every cost, "would this exist if I sold zero units?" Your factory invoice disappears if you make nothing — COGS. Your domain renewal, your accountant, your email marketing tool all bill you whether you sell zero units or ten thousand — operating expense. The handful of genuinely gray costs, like per-order packing labor or transaction-level fees, are worth deciding on once and documenting so you treat them the same way every month. Auditors and lenders care far less about which bucket you choose for the gray cases than about whether you're consistent. Consistency is what turns a pile of receipts into a trend you can actually act on.
Returns are the sneaky one almost nobody budgets for. The National Retail Federation reported that retailers expected about 16.9% of 2024 sales to come back as returns, with online return rates even higher at 17.6%, per NRF and Happy Returns (2024). A returned unit you can't resell isn't just a refund — it's COGS you already spent with zero revenue to show for it. And inventory you never sell at all hurts the same way: U.S. retail shrink reached an estimated $112.1 billion in losses, according to figures reported by Retail Dive citing the NRF (2024). Damaged, lost, or stolen stock is COGS with no sale attached. Build a small buffer for both into your pricing, or they'll quietly eat the margin you thought you had.
Common mistakes with COGS (cost of goods sold)
- Only counting the "obvious" product cost. Founders tally the wax and forget the box, the freight, and the label. Those hidden inputs routinely add 20–40% to true per-unit COGS and quietly turn winning products into losers, exactly like Maya's promotion almost did.
- Ignoring inbound freight and duties. The $3 unit that costs $1.40 to ship from overseas is really a $4.40 unit. Spread shipping and customs across the whole order and assign it per piece, or your margins are fiction.
- Mixing in marketing and overhead. Dumping ad spend, your salary, or your online store subscription into COGS makes your gross margin look terrible and hides which products actually perform. Keep operating costs below the gross-margin line.
- Forgetting returns and shrinkage. A unit that comes back unsellable or never sells at all is COGS with no revenue. With online return rates near 17–18%, pricing as if every unit sells once and stays sold is a slow leak.
- Never updating costs. Supplier prices, freight rates, and packaging costs drift. The COGS you calculated at launch can be 15% stale a year later, so revisit it every quarter and after any reorder.
- Pricing off margin you wish you had. Picking a price first and reverse-engineering a comfortable COGS is how founders convince themselves a bad deal is fine. Cost first, then price — never the other way around.
- Treating every product as one blended number. Your candles and your gift sets have different margins. A single store-wide COGS average hides the products you should push and the ones you should quietly retire.
How Zentrix helps
Zentrix builds your whole business from a single idea — the brand, the store, the legal pages, and a path to real suppliers — and that supplier piece is where COGS gets practical instead of theoretical. The hard part of knowing your true cost is usually sourcing: finding a manufacturer, understanding the wholesale unit price, and seeing the freight and minimums clearly before you commit. When Zentrix sets up your store and connects the pieces, you start with the actual numbers in front of you rather than guessing, which is exactly the inputs you need to calculate honest per-unit COGS from day one.
It also takes the rest of the launch off your plate so you can spend your attention on the math that matters. Naming, brand identity, product copy, and your store all get handled, and free tools like the business plan generator and the product description writer help you think through pricing and positioning before you order a single unit. You can start building your store from one idea, then use the breathing room to do the unglamorous, profit-deciding work of getting your costs right. Explore the full toolkit or see what the platform does if you want the wider picture first.
Frequently asked questions
What is the difference between COGS and operating expenses?
COGS covers the direct cost of the products you sold — materials, manufacturing, packaging, and inbound freight. Operating expenses cover everything else it takes to run the business, like marketing, rent, software, and salaries. The simplest test is whether a cost scales with how many units you sell; if it does, it's usually COGS.
Does COGS include shipping costs?
Inbound shipping — the freight to get products from your supplier to you — is part of COGS because it's a direct cost of acquiring inventory. Outbound shipping to the customer is treated separately and usually sits in fulfillment costs rather than COGS. Keeping the two straight matters because it changes how you read your gross margin.
How do I calculate COGS for a dropshipping store?
For dropshipping, your COGS is mostly the wholesale price your supplier charges for each item, plus any per-order fee they add. Because you hold no inventory, you skip the beginning-and-ending-inventory formula and just total the direct cost of each unit sold. It's one of the cleanest COGS calculations of any business model.
What is a good COGS percentage for a small business?
There's no universal number because it varies wildly by category, but many healthy e-commerce brands keep COGS at 30–50% of the selling price, leaving a 50–70% gross margin. Beauty and digital products run leaner on COGS, while electronics and food run heavier. Compare against your specific niche rather than a single blended benchmark.
How is COGS related to profit margin?
COGS is the main input to gross margin: subtract COGS from your selling price and divide by the price to get the percentage. A lower COGS directly raises your gross margin and gives you more money to spend on ads, shipping, and profit. That's why improving sourcing or packaging costs is one of the highest-leverage things a founder can do.
How often should I update my COGS calculation?
Review it at least every quarter, and always recalculate after a supplier price change, a new freight quote, or a packaging redesign. Costs drift quietly, and a COGS figure that's a year old can be off by enough to make a "profitable" product a losing one. Treat it as a living number, not a launch-day decision you make once.