Cost of Goods Sold (COGS): How to Calculate It and Why It’s Different From Total Expenses
AuthorMehul Jagwani
Reviewed ByCA Ajay Savani

Summary:
Cost of Goods Sold represents the cost associated with the goods you actually sold during a period. For a trading business, the basic COGS formula is Opening Stock + Net Purchases + Direct Costs − Closing Stock. Expenses such as office rent, marketing and administrative salaries are normally kept outside COGS. The more accurately you maintain purchases and inventory, the more reliable your gross profit becomes.
Imagine you run a retail store in Mumbai. Your sales look good, but when you check your profit at the end of the month, the numbers don’t add up. You have purchased new stock, paid shop rent, and covered employee salaries. But how much did the products you actually sold cost you? That’s where understanding how to calculate the cost of goods sold becomes important.
Cost of Goods Sold (COGS) tells you the direct cost of products sold, not your total business expenses. You calculate it by adding opening stock and net purchases, then subtracting closing stock. We will explain the COGS formula, walk through a practical example, and show how Munim helps you track inventory costs and profitability.
What Is the Cost of Goods Sold?
Cost of Goods Sold is the direct cost attributable to the products your business sold during a particular accounting period.
Suppose you run an electrical goods store. You may buy ₹20 lakh worth of inventory during the year, but that does not necessarily mean your COGS is ₹20 lakh.
Why?
Because some of those goods may still be lying in your shop or warehouse at the end of the year. Those unsold goods remain part of your closing inventory rather than becoming an expense through COGS immediately.
This is the basic relationship:
Net Sales − Cost of Goods Sold = Gross Profit
So, if your net sales are ₹30 lakh and your COGS is ₹19 lakh:
Gross Profit = ₹30 lakh − ₹19 lakh = ₹11 lakh
Your gross profit tells you how much remains from sales after covering the cost of the goods you sold. It does not yet account for expenses such as office salaries, advertising, interest or other overheads.
That is why calculating COGS correctly is important before you analyse overall profitability.
Simplify Your Business Operations
Designed to give you speed, control, and accuracy in daily accounting tasks.
Save time with automated accounting workflows
Get 35+ detailed business reports easily
Access your business anytime, anywhere
What Is the COGS Formula?
For most trading and retail businesses, the basic formula is:
COGS = Opening Inventory + Net Purchases + Direct Costs − Closing Inventory
In a simpler situation where all relevant purchase costs are already included in purchases:
COGS = Opening Stock + Purchases − Closing Stock
How to Calculate Cost of Goods Sold Step by Step
To understand how to calculate the cost of goods sold, you need accurate opening stock, purchase records, direct costs and closing stock.
Step 1: Find Your Opening Inventory
Opening inventory is the value of stock available at the beginning of the period.
If you are calculating COGS for FY 2026 27, your opening inventory will generally correspond to the previous financial year’s closing inventory, subject to any required adjustments.
For example:
Opening stock = ₹4,00,000
Step 2: Calculate Your Net Purchases
Assume you purchased goods worth ₹14,00,000 during the year.
You also paid:
- Freight inward: ₹60,000
- Purchase returns: ₹50,000
- Trade discounts: ₹10,000
Net purchases:
₹14,00,000 + ₹60,000 − ₹50,000 − ₹10,000
Net purchases = ₹14,00,000
Step 3: Determine Closing Inventory
Suppose the inventory remaining at the end of the year is valued at:
Closing inventory = ₹5,00,000
This amount represents stock that has not yet been recognised as part of the cost of goods sold.
Step 4: Apply the COGS Formula
COGS = Opening Stock + Net Purchases − Closing Stock
COGS = ₹4,00,000 + ₹14,00,000 − ₹5,00,000
COGS = ₹13,00,000
Your business therefore incurred ₹13 lakh as the cost of the goods sold during the period.
What Costs Should Not Normally Be Included in COGS?
A cost does not become COGS merely because your business paid it.
Several costs relate to running or selling the business rather than acquiring or manufacturing inventory.
Examples can include:
- Office rent
- Advertising expenses
- Sales commissions
- Administrative salaries
- General office electricity
- Accounting fees
- Legal fees
- Selling and distribution expenses
- General storage costs that are not required as part of the production process
COGS vs Operating Expenses: What Is the Difference?
The simplest way to understand COGS vs operating expenses is to look at what each cost relates to.
COGS relates directly to what you sold. Operating expenses relate to running the business.
| Basis | COGS | Operating Expenses |
| Purpose | Cost of goods sold | Cost of running the business |
| Relationship with products | Direct or production related | Usually indirect |
| Appears before | Gross profit | Operating profit |
| Examples | Stock purchases, direct materials, direct labour, eligible freight inward | Office rent, marketing, administrative salaries, office utilities |
| Connected to inventory | Yes, for product businesses | Normally no |
| Main profitability impact | Gross profit | Operating profit and net profit |
Suppose you sell furniture.
The timber used to manufacture a table may form part of inventory cost and ultimately COGS.
Your Instagram advertising bill does not.
The salary of a worker directly involved in manufacturing may be included in conversion cost where appropriate.
The salary of your HR executive normally remains an operating expense.
Separating these costs properly helps you understand whether falling profitability is caused by product cost or overhead.
Why Does COGS Matter to Your Business?
Learning how to calculate the cost of goods sold gives you more than one accounting number. It helps you understand several parts of your business.
1. You Can Measure Gross Profit Correctly
The formula is:
Gross Profit = Net Sales − COGS
If COGS is inaccurate, gross profit will also be inaccurate.
2. You Can Track Gross Profit Margin
Gross Profit Margin = Gross Profit ÷ Net Sales × 100
If your gross margin falls from 30% to 22%, you can investigate whether supplier prices increased, discounts became too aggressive, wastage increased or your selling price failed to keep pace with cost.
3. You Can Improve Pricing Decisions
Knowing your true cost helps you avoid setting prices based only on competitors or purchase invoices.
You can see whether the selling price leaves enough gross profit to cover operating expenses and still generate a reasonable net profit.
4. You Can Measure Inventory Turnover
COGS is also used in the inventory turnover ratio:
Inventory Turnover Ratio = COGS ÷ Average Inventory
This helps you understand how efficiently inventory is moving through your business.
5. You Can Compare Product Performance
If you maintain accurate item costing, you can identify products that produce strong sales but weak margins.
High revenue does not always mean high profit.
Should You Calculate COGS Monthly or Only at Year End?
You can calculate COGS monthly, quarterly or annually depending on your inventory system and reporting needs.
If you only calculate it at year end, you may discover margin problems months after they began.
For example, assume the purchase price of one of your best selling items rises by 12%. If your selling price remains unchanged, your gross margin may shrink immediately.
Monthly or periodic reporting allows you to monitor:
- Changes in purchase cost
- Gross profit
- Product margins
- Stock movement
- Closing inventory
- Wastage and adjustments
- Supplier price increases
How Does Munim Help You Track COGS and Profitability?
Calculating COGS manually becomes difficult when you have hundreds of products, frequent purchases, purchase returns, multiple warehouses and continuous stock movement.
Munim Billing & Accounting keeps purchases, sales and inventory records connected so you can review the cost and profitability information generated from recorded transactions.
We currently provide reports such as:
- Trading and Profit and Loss Report
- Stock Summary Report
- Stock Valuation Report
- Purchase Register
- Item Costing Analyze Report
- Invoice Wise Profit Loss Report
Our report management system uses transaction entries to populate reports and provides real time reporting, reducing the need to rebuild financial information manually whenever you need to review business performance.
This means you can review inventory cost and profitability during the year instead of depending entirely on a manual spreadsheet prepared at year end.
Understand Your Costs to Improve Profitability
Knowing how to calculate the cost of goods sold helps you measure gross profit, manage inventory costs and make better pricing decisions. Keeping COGS separate from operating expenses gives you a clearer picture of your business profitability.
Want to track inventory, expenses and financial reports in one place? Sign up for Munim Billing & Accounting and simplify your everyday business accounting.
Frequently Asked Questions
What is the easiest formula for calculating COGS?
For a simple trading business, COGS = Opening Stock + Purchases − Closing Stock. Where applicable, you should adjust purchases for purchase returns, trade discounts and direct acquisition costs such as eligible freight inward.
Is COGS the same as purchases?
No. Purchases represent goods bought during the period, while COGS represents the cost of goods actually sold. Unsold goods remain in closing inventory and therefore affect the final COGS calculation.
Is COGS an expense?
Yes. COGS is generally recognised as an expense associated with the revenue earned from goods sold during the period. However, inventory that remains unsold continues to be recognised as an asset until it is sold or otherwise accounted for.
Does salary come under COGS?
It depends on what the employee does. Direct labour involved in manufacturing can form part of conversion cost, while administrative, HR, sales and general office salaries normally remain outside COGS.
Is freight included in COGS?
Freight inward that is directly attributable to acquiring inventory and bringing it to its present location can form part of inventory cost. Freight or distribution costs incurred for delivering sold products to customers are generally treated differently and should not automatically be included in inventory cost.
How does closing inventory affect COGS?
Higher closing inventory reduces COGS when other figures remain unchanged, while lower closing inventory increases it. This is why accurate stock counting and valuation are essential for reliable gross profit reporting.
Can a service business have COGS?
A pure service business may not have inventory based COGS in the same way as a retailer or manufacturer. Instead, you may track direct costs of delivering services, such as project specific labour or other directly attributable costs, depending on your accounting presentation.
Can COGS be negative?
COGS would not normally be negative in an ordinary trading or manufacturing business. A negative result may indicate incorrect opening or closing stock, reversed transactions, purchase adjustments, backdated entries or another accounting issue that should be investigated.
Disclaimer: "This blog post is for informational purposes only. For specific tax advice related to your business, please consult a qualified Chartered Accountant or GST practitioner."



