Every business that sells a physical product whether a small retail shop in Kuala Lumpur or a large manufacturing firm in Johor Bahru needs to understand one fundamental accounting figure that sits right at the top of the income statement: the cost of goods sold. This single metric tells you, in precise financial terms, how much it truly costs to produce or acquire the products you sell. Far from being just an accounting formality, understanding and maintaining clear COGS transparency and accurate product cost can be the difference between a thriving, profitable business and one that is slowly bleeding cash without realising it.
In Malaysia’s highly competitive marketplace, where supply chain disruptions, fluctuating raw material prices, and shifting consumer demand are constant realities, keeping a sharp eye on your cost of goods sold is more important than ever. Business owners, finance managers, and operations teams who master this concept gain a powerful lens through which they can evaluate pricing strategies, supplier negotiations, and inventory management practices. This comprehensive guide will walk you through everything you need to know from the fundamental definition to advanced calculation methods, practical examples, and actionable strategies to reduce your overall COGS and improve profit margins.
Key Takeaways
|
What Is Cost of Goods Sold (COGS)?

Cost of Goods Sold (COGS) is the total money spent directly to buy or create the products a business actually sells. It sits right below revenue on your income statement and is used to calculate your gross profit. This figure only includes items sold to customers, meaning unsold products stay on your balance sheet as inventory. For manufacturers, this covers raw materials and labor, while retailers include the purchase price and shipping costs.
It is vital to distinguish COGS from operating expenses, which are background costs like rent, utilities, and marketing. While COGS tracks the “front-line” cost of a specific product, operating expenses cover the general costs of keeping the business running. Separating these two is essential for accurate tax reporting and understanding your true profit margins. This clear distinction helps owners make better decisions about pricing and overall financial health.
Why COGS Matters for Your Business
Understanding your COGS is critical for several reasons:
- Gross Profit Calculation: Gross profit is calculated as Revenue minus COGS. This figure reveals how efficiently a company is producing or sourcing its products before accounting for overhead and other expenses.
- Pricing Decisions: If you do not know your true cost of goods, you cannot set prices that ensure profitability. COGS is the foundation of any sound pricing strategy.
- Tax Deductions: In Malaysia, COGS is a deductible business expense. Accurately reporting it reduces your taxable income and, therefore, your corporate tax liability.
- Operational Efficiency: Tracking COGS over time reveals trends in production costs, supplier pricing, and waste, enabling management to identify inefficiencies and take corrective action.
- Investor and Lender Confidence: A clearly reported and well-managed COGS figure signals financial discipline to investors, lenders, and other stakeholders.
Understanding the inventory cycle is closely tied to how COGS is tracked. From the moment goods are ordered from a supplier to the point they are sold to a customer, every stage in the inventory lifecycle has a cost implication that feeds directly into COGS. Businesses that manage their inventory cycle effectively will find it far easier to control and predict their cost of goods sold.
The COGS Formula Explained
The standard formula for calculating cost of goods sold is straightforward:
COGS = Opening Inventory + Purchases During the Period − Closing Inventory
Let’s break down each component:
- Opening Inventory: This is the value of inventory you had on hand at the start of the accounting period. It is the same figure as the closing inventory from the previous period.
- Purchases During the Period: This includes all inventory purchased or manufactured during the period, including the cost of raw materials, direct labour for manufacturers, and any import duties or freight costs necessary to bring goods to their current location and condition.
- Closing Inventory: This is the value of inventory remaining unsold at the end of the accounting period. It is determined through a physical stock count or perpetual inventory system.
COGS Calculation: A Step-by-Step Example
Let’s say a Malaysian electronics retailer, TechPlus Sdn Bhd, is calculating its COGS for the financial year ending 31 December 2024:
- Opening Inventory (1 January 2024): RM 150,000
- Purchases During 2024: RM 820,000
- Closing Inventory (31 December 2024): RM 180,000
COGS = RM 150,000 + RM 820,000 − RM 180,000 = RM 790,000
This means TechPlus spent RM 790,000 to acquire the goods it sold during the year. If total revenue was RM 1,200,000, then gross profit would be RM 410,000, a gross margin of approximately 34.2%.
COGS for Manufacturers
For manufacturers, the formula expands to account for the cost of production. The calculation typically involves three types of inventory:
- Raw Materials Inventory: The cost of materials used in production.
- Work-in-Progress (WIP) Inventory: The cost of goods that are partially completed.
- Finished Goods Inventory: The cost of completed products ready for sale.
The Cost of Goods Manufactured (COGM) is first calculated and then fed into the COGS formula as follows:
COGS = Opening Finished Goods + COGM − Closing Finished Goods
Where COGM = Opening WIP + Raw Materials Used + Direct Labour + Manufacturing Overhead − Closing WIP
This layered approach ensures that every production-related cost from the steel used to make a component to the wages of the factory worker assembling it is correctly captured in the cost of goods sold figure.
What Is (and Isn’t) Included in COGS
One of the most common sources of error in COGS calculation is including costs that should not be there, or omitting costs that should be. Getting this right is essential for accurate financial reporting.
What to Include in COGS
- Raw materials and components used directly in production
- Direct labour costs wages and salaries of workers directly involved in making the product
- Manufacturing overhead factory rent, machinery depreciation, factory utilities, and production supervision costs
- Purchase price of goods resold by retailers and wholesalers
- Freight and shipping costs to bring inventory to its current location
- Import duties and customs costs associated with acquiring inventory
- Packaging materials that are integral to the product
- Storage costs directly related to holding inventory for production purposes
What to Exclude from COGS
- Selling expenses advertising, marketing, commissions paid to sales staff
- Administrative expenses management salaries, office rent, legal fees
- Research and development costs
- Depreciation on non-production assets such as company vehicles used by the sales team
- Interest expenses on business loans
- Distribution and delivery costs for outbound shipments to customers (these are typically selling expenses)
Misclassifying these expenses distorts your gross profit and makes it harder to benchmark performance against industry standards or make accurate comparisons across reporting periods.
Inventory Valuation Methods for COGS
Because inventory prices fluctuate over time, businesses must choose an inventory valuation method that determines which costs are assigned to COGS and which remain in ending inventory. The method chosen can significantly impact reported profit, tax liability, and balance sheet values. There are three primary methods used in Malaysia and internationally.
1. First-In, First-Out (FIFO)
FIFO assumes that the oldest inventory items are sold first. This means that when you calculate COGS, you use the cost of the oldest units purchased. Conversely, the inventory remaining on hand reflects the cost of the most recently purchased items.
Example: A food manufacturer purchased 1,000 units at RM 5 per unit in January and 1,000 units at RM 6 per unit in March. If 1,200 units were sold during the period, under FIFO, COGS would be calculated as: (1,000 × RM 5) + (200 × RM 6) = RM 5,000 + RM 1,200 = RM 6,200.
Advantages of FIFO:
- Reflects the natural flow of most physical goods (especially perishables)
- Ending inventory reflects current market prices, making the balance sheet more accurate
- Generally accepted under both MFRS (Malaysian Financial Reporting Standards) and IFRS
Disadvantages of FIFO:
- During periods of rising prices, FIFO results in lower COGS and higher taxable profit
- May not match current costs with current revenues, potentially overstating profitability
2. Last-In, First-Out (LIFO)
LIFO assumes that the most recently acquired inventory is sold first. This results in COGS reflecting more current (and often higher) costs during inflationary periods, and ending inventory reflecting older, lower costs.
Important note for Malaysian businesses: LIFO is not permitted under Malaysian Financial Reporting Standards (MFRS) or International Financial Reporting Standards (IFRS). It is only allowed under US GAAP. Malaysian companies using MFRS must use either FIFO or the Weighted Average Cost method.
3. Weighted Average Cost (WAC)
The Weighted Average Cost method calculates a new average cost for each unit after every purchase, and this average is used for both COGS and ending inventory valuation.
Formula:
Weighted Average Cost per Unit = Total Cost of Goods Available for Sale ÷ Total Units Available for Sale.
Example: Using the same scenario as above 1,000 units at RM 5 and 1,000 units at RM 6, total goods available = 2,000 units at a total cost of RM 11,000. Weighted average cost = RM 11,000 ÷ 2,000 = RM 5.50 per unit. If 1,200 units were sold: COGS = 1,200 × RM 5.50 = RM 6,600.
Advantages of WAC:
- Simple and easy to apply, especially with large volumes of similar items
- Smooths out price fluctuations, providing a more stable COGS figure
- Widely used and accepted under MFRS
Choosing the right valuation method is a critical decision that impacts your long-term financial reporting and tax obligations in Malaysia. It is directly tied to how accurately you manage your ending inventory, as any errors here will lead to incorrect COGS and profit figures. Because changing methods later can be difficult, it is best to consult an accountant to ensure your closing stock values remain precise and compliant.
COGS, Gross Profit, and Gross Margin: Understanding the Relationship
COGS forms the foundation of several critical financial metrics that every business leader should understand and monitor regularly.
Gross Profit
Gross Profit = Net Revenue − COGS
This is the pool of funds from which you must cover all operating expenses (salaries, rent, marketing), finance costs, and ultimately generate net profit. A healthy gross profit is the first gatekeeper of business sustainability.
COGS Margin
The COGS margin is essentially the inverse of gross margin. It represents COGS as a percentage of revenue:
COGS Margin (%) = (COGS ÷ Net Revenue) × 10
A rising COGS margin over time is a warning signal it indicates that costs are increasing faster than revenue, squeezing profitability. Tracking this metric quarterly is a best practice for any business that sells physical goods.
Tracking COGS margin alongside your overall profit margin gives you a complete picture of financial health. While a healthy gross margin is encouraging, it is only truly meaningful when viewed in the context of all other costs the business incurs.
Gross Margin
Gross Margin (%) = (Gross Profit ÷ Net Revenue) × 100
It is one of the most widely used profitability metrics for benchmarking against competitors and industry averages. For example, a Malaysian apparel retailer with RM 2 million in revenue and RM 1.2 million in COGS would have a gross margin of 40%.
Different industries have very different benchmark gross margins:
| Industries | Estimated Gross Margins (%) |
|---|---|
| Retail (general merchandise) | 25–40% |
| Manufacturing | 20–35% |
| Food and Beverage | 30–50% |
| Software/Technology | 60–80% (lower COGS relative to revenue) |
| Construction | 15–25% |
COGS vs. Operating Expenses: A Critical Distinction
Confusing COGS=”citation-3″> with Operating Expenses (OpEx)</span><span class=”citation-3 citation-end-3″> is a common mistake that can lead to inaccurate financial reporting. To keep it simple, ask yourself if a cost is directly needed to make or buy the product you sold; if so, it’s COGS. If the cost exists just to keep the business running regardless of sales—like rent or marketing—it is OpEx.
This distinction is crucial for calculating your true gross profit versus your operating profit. In Malaysia, while both are tax-deductible, they are categorized differently on your income statement to show how efficiently you are producing goods. Understanding this helps you perform better break-even analysis and set smarter pricing strategies for your products.
How to Reduce Your Cost of Goods Sold

Reducing COGS is one of the most powerful levers available to improve gross profit without needing to raise prices. There are several strategies that businesses in Malaysia and globally can deploy effectively.
1. Renegotiate Supplier Contracts
Your suppliers are often your biggest cost driver. Regularly reviewing and renegotiating terms particularly for your top-spend categories can yield significant savings. Strategies include:
- Consolidating purchases with fewer suppliers to achieve better volume discounts
- Negotiating longer payment terms, freeing up working capital
- Exploring local sourcing to reduce import duties and freight costs
- Requesting early payment discounts if you have sufficient cash flow
2. Reduce Waste and Spoilage
For manufacturers and F&B businesses especially, waste is a silent profit killer. Implementing lean manufacturing principles, tightening quality control processes, and monitoring yield rates can dramatically reduce the amount of material that is wasted and therefore the cost per unit of goods produced.
3. Optimise Inventory Levels
Maintaining too much stock increases storage costs and the risk of spoilage, while carrying too little leads to lost sales. The goal is to reach a balance using techniques like just-in-time (JIT) ordering and ABC classification.Effective inventory control is one of the most impactful ways to reduce COGS.
4. Improve Production Efficiency
For manufacturers, increasing production efficiency reduces the direct labour and overhead cost per unit. This can be achieved through:
- Investing in automation and machinery upgrades
- Standardising production processes to reduce variability
- Cross-training workers to improve flexibility and reduce idle time
- Implementing preventive maintenance programs to reduce costly equipment downtime
5. Review Product Mix
Not all products carry the same COGS margin. Regularly analysing the profitability of each product SKU and shifting focus through pricing, promotions, or sales strategy toward higher-margin products is a smart way to improve overall gross margin without necessarily reducing absolute COGS.
6. Leverage Technology for Real-Time Cost Tracking
Manual spreadsheets and disconnected systems often make tracking COGS slow and prone to errors. Modern software automates these calculations, providing real-time visibility into cost changes and flagging problems early. Cloud-based solutions, integrate inventory and finance data into a single platform for more accessible tracking.
Using Technology to Manage COGS More Effectively

In today’s digital business environment, relying on manual processes to track cost of goods sold is both time-consuming and error-prone. Technology has transformed the way businesses can manage inventory costs, providing real-time data that enables faster and better decision-making.
-
Inventory Management Software
A robust inventory management system can automate many of the processes that feed into COGS calculation, including:
- Real-time tracking of stock movements (receipts, transfers, adjustments, sales)
- Automatic application of the chosen inventory valuation method (FIFO or WAC)
- Generation of stock count reports for period-end COGS calculations
- Alerts for slow-moving stock that may be at risk of obsolescence
-
ERP Systems
ERP systems connect inventory data with purchasing, production, and finance into a single platform. This removes the need for manual data entry and significantly reduces the risk of human error. By unifying these departments, businesses can generate accurate, real-time COGS figures instantly rather than waiting for the end of the month
-
Barcode and RFID Technology
Accurate stock counts are the foundation of accurate COGS. Barcode scanning and RFID technology dramatically speed up stocktaking processes and reduce human error, ensuring that the closing inventory figure used in the COGS formula is reliable.
-
Data Analytics and Dashboards
Beyond basic tracking, analytics tools can help businesses identify cost patterns, benchmark COGS margin against budget and prior periods, and model the impact of cost changes on profitability. Custom dashboards that surface key COGS metrics give management the real-time visibility needed to respond quickly to cost pressures.
COGS Considerations for Malaysian Businesses
For businesses operating in Malaysia, there are several specific considerations when calculating and reporting COGS:
Sales and Service Tax (SST)
Under Malaysia’s Sales and Service Tax framework, sales tax is charged on the sale of taxable goods at the manufacturing and import level. Businesses that are registered manufacturers or importers must carefully account for the sales tax component when calculating inventory costs. In most cases, SST paid on inputs that form part of COGS is included in the cost basis of inventory.
Malaysian Financial Reporting Standards (MFRS)
Malaysian companies are required to follow MFRS, which is largely aligned with IFRS. Under MFRS 102 (Inventories), inventories must be valued at the lower of cost or net realisable value. The standard permits FIFO and Weighted Average Cost methods but explicitly prohibits LIFO. Businesses must apply their chosen method consistently from period to period.
Transfer Pricing
For Malaysian businesses that are part of multinational groups or that conduct transactions with related parties, transfer pricing rules apply. The Inland Revenue Board of Malaysia (LHDN) requires that intercompany transactions including the purchase of inventory from related parties be conducted at arm’s length prices. This affects the cost base of inventory and therefore COGS.
COGS is more than a required accounting entry; it is the baseline of your operational survival. If you calculate product costs manually at the end of the month, you are pricing today’s goods using yesterday’s data. In a volatile market, real-time cost visibility is the only true defense for your profit margins.
Conclusion
Mastering your Cost of Goods Sold (COGS) is the best way to protect your profits in Malaysia. It is more than just an accounting number; it is the foundation for setting the right prices and filing your taxes correctly. By clearly separating what it costs to make a product from what it costs to run your office, you can see exactly how much you spend to bring each item to market.
Managing COGS well means choosing a clear way to value your stock, such as the FIFO or Weighted Average methods. Regularly checking these costs helps you find waste and negotiate better deals with your suppliers so rising costs don’t eat your profits. Switching from manual math to automated software gives you the live data you need to make smart financial choices and grow your business.
FAQ About Cost of Goods Sold
-
Why is calculating COGS manually or with basic accounting software often inaccurate?
Basic accounting tools usually don’t connect directly with warehouse data. This forces businesses to use manual data entry or spreadsheets, which often leads to mistakes in stock value and hidden profit losses. For companies with a lot of sales, these delays make it harder to get an accurate picture of their finances on time
-
Which inventory valuation methods are legally permitted in Malaysia?
Under the Malaysian Financial Reporting Standards (MFRS), businesses must use either the First-In, First-Out (FIFO) or the Weighted Average Cost (WAC) method to calculate COGS. The Last-In, First-Out (LIFO) method is strictly prohibited. Modern ERP systems automatically apply these compliant methods across all transactions, reducing the risk of audit penalties.
-
How is COGS calculated differently for manufacturing businesses?
Unlike retailers who simply track the purchase price of finished goods, manufacturers must calculate the Cost of Goods Manufactured (COGM) first. This includes raw materials, Work-in-Progress (WIP), direct labor, and manufacturing overhead. Tracking these layered costs accurately usually requires an integrated manufacturing system rather than standalone finance software.
-
What is the difference between COGS and Operating Expenses (OpEx)?
COGS includes all direct costs tied to producing or acquiring the goods you sell, such as raw materials and direct factory labor. Operating Expenses (OpEx) are the indirect, day-to-day costs of running the business, like office rent, marketing, and administrative salaries. Misclassifying these two is a common error that distorts gross profit margins and impacts tax deductions.
-
How can businesses effectively reduce their Cost of Goods Sold?
Businesses can lower COGS without compromising product quality by renegotiating supplier contracts, minimizing warehouse waste, and optimizing inventory levels to prevent overstocking. Additionally, upgrading to an integrated inventory management system allows businesses to track cost fluctuations in real time and identify operational inefficiencies before they impact the bottom line.






