Cost of sales calculator

Calculators

Enter revenue and your inventory figures to get cost of sales, the cost of sales ratio, gross profit, and gross margin. Everything runs in your browser; your data is never uploaded.

Cost of sales calculator

Cost of sales (also called cost of goods sold, or COGS) is the direct cost of the goods you sold in a period. This calculator works it out with the inventory method — cost of sales = beginning inventory + purchases − ending inventory — and, if you add revenue, also returns the cost of sales ratio, gross profit, and gross margin. Everything runs in your browser; nothing is uploaded.

How it works

Enter four numbers. Cost of sales comes from the three inventory figures; the ratio and profit figures need revenue as well.

OutputFormulaNeeds
Cost of salesBeginning inventory + Purchases − Ending inventoryThe 3 inventory fields
Cost of sales ratioCost of sales ÷ Revenue+ Revenue
Gross profitRevenue − Cost of sales+ Revenue
Gross marginGross profit ÷ Revenue+ Revenue

Steps

  1. Enter your revenue (net sales) for the period.
  2. Enter beginning inventory (opening stock at cost).
  3. Enter purchases made during the period.
  4. Enter ending inventory (closing stock at cost).
  5. Read the cost of sales, ratio, gross profit, and gross margin — they update as you type.

Example: revenue $10M, beginning inventory $2M, purchases $6M, ending inventory $1.5M → cost of sales = 2 + 6 − 1.5 = $6.5M, ratio 65%, gross profit $3.5M, gross margin 35%.

Cost of sales vs. operating expenses

Cost of sales covers only the direct cost of what you sold (purchases or production cost). Advertising, salaries, and rent are operating expenses and are not part of cost of sales. If you don't hold inventory, set beginning and ending inventory to 0 and cost of sales equals your purchases.

Nothing you type is sent anywhere — the whole calculation happens on your device.

Operated by

Turnint AI
unbounded pioneering inc

Turnint AI Tools is a suite of free tools built and operated by unbounded pioneering inc, the company behind the Turnint AI agent platform.

Ryosuke Suzuki
Ryosuke SuzukiFounder & CEO

Founder & CEO of Unbounded Pioneering Inc., the company behind the Turnint AI agent platform, and an expert in machine learning and AI product development. He began his career in machine learning research at a university laboratory, then designed and built large-scale products as a software engineer at PLAID, Rakuten, and Recruit, while also driving new business development. Now specializing in generative AI and AI agents, he works across both engineering and business development, and is a named inventor on multiple granted patents in web technology.

Named inventor on granted patents JP6887648 & JP7480958 · Patent pending on Turnint AI technology

Get in touch

Thanks for reaching out

Thank you for your interest in our company. A member of our team will get back to you within one business day.

What we can help with

  • Adopting and getting the most out of Turnint AI
  • A demo or trial of Turnint AI
  • AI adoption in general (beyond our own product, too)
  • Alliances and partnerships
  • Any other questions

Talk to us online

You can also book a meeting directly from the calendar.

Pick a template or write your own message.