# Cost of Goods Sold (COGS): How to Calculate It Correctly
*The number that sets your profit margin, and the one small business owners understand least*

> **In short:** A practical guide to cost of goods sold (COGS): the formula, revenue versus gross profit, worked examples from Saudi sectors, and what the number changes.

- **URL:** https://www.snad.io/en/blog/takalif-bidaa-mabia-cogs-dalil
- **Arabic original:** https://www.snad.io/blog/takalif-bidaa-mabia-cogs-dalil
- **Category:** Guides — Core Accounting
- **Tags:** accounting, accounting basics, profitability, cost, financial reports
- **Published:** 2026-05-10
- **Updated:** 2026-08-02
- **Publisher:** Snad (snad.io)

The question that puzzles most small business owners in Saudi Arabia is a simple one: "How much do I actually make on every SAR of revenue?" Answering it honestly starts with a single number: cost of goods sold, or COGS. Many owners blur the line between revenue and profit, and between gross profit and net profit. A shop owner selling SAR 500,000 a month may assume the business is earning well, while COGS alone eats SAR 350,000 of that. Only SAR 150,000 of the revenue is left, and it has to cover rent, salaries and electricity before the owner keeps a single SAR. Knowing your COGS precisely turns decisions from guesswork into arithmetic: you learn what to sell, which product earns money, and which one drains your balance. This guide is written for the small business owner who wants to understand a number that ought to be basic but is, in practice, neglected.

## What is cost of goods sold?

Cost of goods sold is the total of the direct costs attached to producing or buying the goods you actually sold during a defined period (a month, a quarter, a year).

The key phrase is "actually sold". Not everything you bought, only what you sold.

A simple example: in January you bought SAR 100,000 of goods, you sold SAR 80,000 of them (at cost), and SAR 20,000 of inventory was left. **COGS for January = SAR 80,000** (not SAR 100,000).

What belongs inside COGS:

- **The direct cost of the item**: the price you paid the supplier.
- **Freight and import insurance**: whatever it takes to get the goods into your warehouse.
- **Customs duties**: on imported goods.
- **Raw material cost**: where there is manufacturing or conversion (a restaurant, a bakery, a small factory).
- **Direct labor**: for factories and kitchens, meaning cooks' wages and production workers. (But not salespeople or administrative staff.)
- **Direct conversion costs**: kitchen electricity and gas in a restaurant, production machinery maintenance in a factory.

What does not belong inside COGS:

- Salaries for management, salespeople and reception.
- General rent for the premises.
- Marketing and advertising.
- General electricity.
- Telecoms.
- Depreciation on administrative assets.

Those are called "operating expenses" and they are recorded below gross profit.

## How to calculate it: the core formula

The formula is classic and simple:

**COGS = opening inventory + purchases during the period − closing inventory**

A worked example for a retail store:

- Inventory on 1 January: SAR 200,000.
- January purchases: SAR 300,000.
- Inventory on 31 January (after the count): SAR 250,000.

**COGS for January** = 200,000 + 300,000 − 250,000 = **SAR 250,000**.

The logic holds: what you started with + what you bought − what was left at the end = what left inventory. Whatever left inventory is presumed sold (or lost, or damaged, and those need to be told apart).

**An important note**: the closing count is the single biggest factor in accuracy. If you never counted physically and simply trusted the system figure without confirming it, your number may be wrong, whether through theft, unrecorded damage or entry errors. Either way it inflates or understates COGS.

**Where there is production (a factory, a restaurant, a bakery)**:
The formula gets more involved. You need:
- Opening inventory of raw materials + work in progress + finished goods.
- Purchases, direct labor and conversion costs during the period.
- Closing inventory across all three categories.

At that point you need an accounting system that handles "recipes" and conversion costs, because working it out by hand stops being practical.

## Examples from different Saudi sectors

**Example 1: a clothing shop in Riyadh**
- February revenue: SAR 200,000.
- Inventory on 1 February: SAR 80,000.
- February purchases: SAR 100,000.
- Inventory on 28 February: SAR 75,000.

COGS = 80,000 + 100,000 − 75,000 = **SAR 105,000**.
Gross profit = 200,000 − 105,000 = **SAR 95,000**.
Gross margin = 95,000 / 200,000 = **47.5%** (good for the retail sector).

**Example 2: a mid-sized restaurant in Jeddah**
- Revenue for the month: SAR 350,000.
- COGS (raw materials + direct kitchen labor + gas): SAR 130,000.

Gross profit = 350,000 − 130,000 = **SAR 220,000**.
Gross margin = 62.8% (normal for restaurants).

But watch out: this is before rent, administrative salaries, general electricity and marketing. Net profit may be only 15-25%.

**Example 3: a consulting services firm**
Service firms have no conventional COGS because they do not sell goods. They use cost of services instead, which covers:
- Salaries of the consultants working on the projects.
- Subscriptions to the technical software in use.
- Travel costs to reach clients.

The logic is the same: direct costs of delivering the service, deducted from service revenue to arrive at gross profit.

## How COGS drives gross margin

Gross margin = (revenue − COGS) / revenue × 100%.

That number tells you one thing: out of every SAR sold, how much is left after paying for the product itself?

**Common sector benchmarks**:

- General retail shop: 25-45%.
- Restaurant: 55-70%.
- Bakery: 50-65%.
- Beauty salon: 60-75% (because the service consumes few materials).
- Auto parts shop: 25-40%.
- Consulting services firm: 50-70%.

If your margin sits noticeably below the sector norm, you are dealing with one of three problems:

1. **A low selling price**: you compete on price alone, so you sacrificed your margin. The fix: raise prices gradually, or add value that justifies the price.
2. **A high purchase cost**: your suppliers charge you above the market. The fix: compare 3-5 suppliers and negotiate on larger volumes.
3. **Waste or theft in inventory**: COGS is high because goods disappear without being sold. The fix: periodic counts, a tracking system, a minimum level of control.

**An important point**: watch the direction of the margin, not a single reading. If your margin was 38% last month and 32% this month, that is a warning worth investigating. Do not wait for it to fall to 22%.

## Common mistakes in calculating COGS

**1. Mixing COGS with operating expenses**:
Putting shop rent or the manager's salary inside COGS inflates the number and corrupts the accounts. The rule: COGS covers the direct costs of producing the goods sold, and nothing else.

**2. Booking purchases straight to COGS**:
You bought SAR 100,000 of goods this month and recorded all of it as COGS. That is wrong. COGS is what you actually sold, not what you bought. The difference stays in inventory.

**3. Skipping the physical count**:
Relying on a system figure assumes every sale, purchase and return was recorded accurately. A monthly or quarterly physical count corrects those assumptions.

**4. Ignoring damaged inventory**:
Expired goods, damaged goods and severely stagnant goods have to be recorded as an inventory write-down or inside COGS. Ignoring them inflates the inventory balance and breaks the formula.

**5. Not tracking freight and import costs**:
You bought goods for SAR 50,000 + SAR 5,000 freight + SAR 7,500 customs = an actual cost of SAR 62,500. Recording only SAR 50,000 hides SAR 12,500 of the real cost.

**6. Confusing "selling price" with "cost price"**:
When you count inventory, value it at cost, not at the selling price. Mixing the two ruins every calculation.

**7. Forgetting sales returns**:
A customer returns goods, they go back into inventory, but the system is never updated. Physical inventory then falls short of the figure in the books.

## How Snad helps you track COGS accurately

Working out COGS by hand every month is a burden. A sound accounting system calculates it automatically:

- **Real-time inventory tracking**: every sale automatically deducts from the inventory balance at the product's cost. Every purchase (GRN) adds to inventory at its full cost, including freight and customs.
- **Weighted average costing**: when purchase prices fluctuate, the system computes an average that keeps COGS accurate.
- **An income statement that shows COGS and gross margin automatically**: no manual calculations. You see the number and the explanation for its movement in one click.
- **Cost reports by product**: you know the margin on every item, so you can concentrate on the most profitable ones.
- **Damaged and stagnant inventory reports**: they help you avoid inflating the inventory balance.
- **Cost centres**: to analyse COGS by branch or department. You may discover that a single branch is consuming goods uneconomically.
- **Structured periodic counts**: through the inventory app you run a methodical count and settle the differences with an automatic journal entry.
- **Integration with sales and purchasing**: every sale flows through to COGS automatically, with no duplicated manual entries.

The 30-day free trial lets you try these tools on your own live data and see what they do for the accuracy of your income statement.

## A practical summary for the owner

Five rules that turn COGS into a number you trust and can decide on:

1. **Understand the formula yourself**: do not let your accountant hand you figures you cannot follow. Opening inventory + purchases − closing inventory = COGS. That is the foundation.
2. **Count physically once a month for high-value items**, and run a full count every 3 months: do not rely on system numbers without periodic confirmation.
3. **Separate COGS from operating expenses clearly in your chart of accounts**: this is a pivotal point in building a sound chart of accounts.
4. **Watch the gross margin trend every month**: a drop of 3% or more deserves immediate investigation.
5. **Use an accounting system that calculates COGS automatically and links each sale to an inventory deduction**: manual calculation invites errors.

Understanding COGS and tracking it accurately moves your thinking from "how much did we sell?" to "how much did we actually make?", and that difference is the difference between a company that grows and one that spins in place.

## Frequently asked questions

### Does my service business need to track COGS?

Yes, under the term cost of services. It covers the direct salaries of the people delivering the service, subscriptions to tools that serve clients directly, and travel costs for projects. The gap between service revenue and those costs is the gross margin, and knowing it is the basis for pricing future contracts.

### How often should I calculate COGS?

Monthly at a minimum, especially in sectors with thin margins (restaurants, bakeries, retail). A weekly figure is useful for fast-moving businesses. Quarterly is the minimum for service firms. A sound accounting system calculates it automatically with every income statement.

### What is the difference between COGS and operating expenses?

COGS is the direct cost of producing or buying the goods sold. Operating expenses are the costs of running the company in general (rent, management salaries, marketing, general electricity). COGS is deducted from revenue to arrive at gross profit. Operating expenses are deducted from gross profit to arrive at operating profit.

### How do I handle damaged goods in the COGS calculation?

Damaged goods were not sold, but they did leave inventory. Record them through an inventory impairment provision entry or directly inside COGS, as both treatments are accepted accounting practice. What matters is that they do not remain in the inventory balance as though they were still saleable. That inflates assets and improves COGS misleadingly.

### Does Value Added Tax (VAT) on purchases go into COGS?

If your company is registered for VAT and recovers input tax, the VAT paid on purchases does not go into COGS (it is recorded as an amount receivable from the Zakat, Tax and Customs Authority (ZATCA)). If you are not registered for VAT, or your activity is exempt, the VAT becomes part of the purchase cost and does go into COGS.

---
## About the publisher
**Snad (سند)** — a private Saudi software company
based in Riyadh, founded 2025. Legal form: Sole proprietorship.
Commercial registration: 7038154642
VAT number: 310959226500003
Only official domain: snad.io
> Snad is a private commercial business-management platform. It is not a
> government body, not a bank, and not a government services portal, and it
> is not affiliated with any government entity. Any site or app with a
> similar name is unrelated to Snad.