Gross profit margin formula: definition, steps, example
Learn the gross profit margin formula to price smarter, cut costs, and grow profit.
Written by Lena Hanna—Trusted CPA Guidance on Accounting and Tax. Read Lena's full bio
Published Saturday 21 February 2026
Table of contents
Key takeaways
- Calculate your gross profit margin by subtracting cost of goods sold from revenue, dividing by revenue, and multiplying by 100 to get a percentage that shows how much profit you keep from each dollar of sales.
- Include only direct production costs like materials and direct labour in your cost of goods sold calculation, avoiding operating expenses like rent and marketing to ensure accurate margin calculations.
- Compare your gross profit margin against industry benchmarks regularly, as good margins typically range from 25% to 50% depending on your sector, with service businesses often achieving higher margins than retail or manufacturing.
- Improve your gross profit margin by adjusting prices strategically, negotiating better supplier terms, reducing waste in production, and streamlining operations to lower your direct costs.
What is gross profit margin?
Gross profit margin is the percentage of sales revenue remaining after you subtract the cost of goods sold (COGS). It shows how efficiently your business produces and sells its products or services.
After paying operating expenses like rent and utilities, the remainder becomes your net profit.
A healthy gross profit margin helps you:
- cover essential business expenses
- reinvest in growth
- build a buffer against market changes
Low margins make it harder to pay for overhead costs and reduce your chances of turning a net profit.
Gross profit margin formula

The gross profit margin formula is:
Gross Profit Margin = ((Revenue - COGS) ÷ Revenue) × 100
Here's what each component means:
- Revenue: total sales income before any deductions
- COGS (cost of goods sold): direct costs to produce or deliver your products or services
- Result: a percentage showing how much of each dollar you keep after covering direct costs
For example, a 40% gross profit margin means you keep $0.40 from every $1 of revenue after paying for COGS.
Gross profit margin vs gross profit
Gross profit and gross profit margin measure the same thing differently:
- Gross profit: a dollar amount (Revenue minus COGS)
- Gross profit margin: a percentage (Gross Profit divided by Revenue, times 100)
Both metrics help you understand profitability, but the percentage format makes it easier to compare performance across time periods or against industry benchmarks.
The term "gross margin" means the same thing as gross profit margin.
How to calculate gross profit margin
Follow these steps to calculate your gross profit margin accurately.
Gross profit margin calculation
To calculate your gross profit margin, follow these steps:
- Find your total revenue (sales income)
- Subtract your cost of goods sold (COGS) to get gross profit
- Divide gross profit by revenue
- Multiply by 100 to get a percentage
Your accounting software or profit and loss statement should have these figures ready.
Here's what each part of the formula means.
Gross profit margin formula explained
Revenue includes all income from sales before any deductions. Use your total sales figure, not amounts after discounts or returns.
Cost of goods sold (COGS) covers the direct costs of producing what you sell. This includes materials, direct labour, and manufacturing costs, but not overhead expenses like rent or marketing.
Getting COGS right is critical. If you underestimate it, your margin will look better than it actually is.
Gross profit margin example calculation
Here's how a cleaning business would calculate its gross profit margin:
- Revenue: $20,000 (income from cleaning offices)
- COGS: $8,000 (supplies, direct labour costs)
- Gross profit: $20,000 - $8,000 = $12,000
- Gross profit margin: ($12,000 ÷ $20,000) × 100 = 60%
A 60% margin means this business keeps $0.60 from every dollar of revenue after covering direct costs.


Understanding cost of goods sold
Cost of goods sold (COGS) includes only the direct costs of producing your products or delivering your services.
COGS typically includes:
- raw materials and supplies
- direct labour (wages for production staff)
- manufacturing overhead
- shipping costs for materials
COGS does not include:
- rent and utilities
- marketing and advertising
- administrative salaries
- office supplies
For service businesses, COGS might be lower since you're selling time and expertise rather than physical products. Your main costs may be labour and any materials used to deliver the service.
Learn more about calculating your cost of goods sold in the COGS guide.
Avoid common calculation mistakes
Accurate COGS is essential for a meaningful gross profit margin. Here are common errors to watch for:
- Including operating expenses in COGS: rent, utilities, and marketing are overhead costs, not direct production costs
- Forgetting indirect labour: include wages for staff directly involved in production or service delivery
- Mixing up revenue figures: use gross revenue (total sales), not net revenue after discounts
- Using inconsistent time periods: make sure your revenue and COGS cover the same dates
Review your calculations quarterly to catch errors before they affect business decisions.
What is a good gross profit margin?
A good gross profit margin typically ranges from 25% to 50%, though this varies significantly by industry. Service businesses often achieve 50% or higher, while retail and manufacturing may operate at 25% to 35%.
Your margin needs to be high enough to cover:
- operating expenses (rent, utilities, salaries)
- taxes and loan repayments
- reinvestment in the business
The right target depends on your industry, business size, and market conditions.
Factors affecting your margins
Several factors determine what counts as a "good" margin for your business:
- Industry: service businesses often have higher margins than retail or manufacturing due to lower direct costs
- Region: local costs, taxes, and customer spending power vary significantly by location
- Business model: ecommerce typically has lower overhead than brick-and-mortar stores, allowing for better margins
- Competition: crowded markets often force lower prices, which compresses margins
Compare your margin against similar businesses in your industry and region for the most useful benchmark.
Benchmarking your gross profit margin
Comparing your margin against similar businesses shows whether you're performing well or need to make changes.
For accurate benchmarking:
- compare against businesses of similar size in your industry
- look at competitors in your region or market
- track your own margin over time to spot trends
- ask your accountant for industry-specific data
Your accountant or bookkeeper can help you find reliable benchmark data for your sector.
Industry benchmarks for gross profit margin
Gross profit margins vary widely by sector. Here are typical ranges:
- Jewellery and cosmetics: 55% or higher
- Software and SaaS: 70% to 85%
- Professional services: 50% to 70%
- Restaurants and hospitality: 30% to 40%
- Retail (general): 25% to 35%
- Electronics: 20% to 40%
- Grocery: 20% to 30%
Your accountant can help you find specific benchmarks for your industry and clarify what margin your business should target.
When to reassess your gross profit margin
Review your gross profit margin regularly, and especially when:
- your costs increase (materials, labour, shipping)
- you're missing growth or profit targets
- market conditions shift significantly
- you're planning price changes
- you're expanding into new products or services
Monthly reviews help you spot problems early. Quarterly deep dives let you compare performance against benchmarks and adjust your strategy.
Analysing gross profit margin for business insights
Analysing your gross profit margin reveals which products, services, or business areas generate the most profit, helping you focus resources where they matter most.
Two levers drive your margin:
- Pricing: competitive pricing attracts customers, but prices too low squeeze profits
- Costs: reducing COGS directly increases your margin
Tracking margins by product line or service type shows where to invest and where to cut back.
Interpreting gross profit margin trends
Tracking your margin over time reveals patterns that single calculations miss.
Look for:
- Seasonal changes: margins may dip during slow periods or spike during peak demand
- Product performance: some items consistently deliver higher margins than others
- Cost creep: gradually rising COGS that erode profitability
- Pricing impact: how price changes affect both sales volume and margin
Compare month-over-month and year-over-year to separate seasonal patterns from genuine trends.
Factors affecting gross profit margin
External factors outside your control can shift your margin:
- Market demand: falling demand may force price cuts to maintain sales volume
- Supplier costs: rising material or labour costs directly reduce your margin
- Economic conditions: when customers have less to spend, your revenue may drop
- Competition: new competitors or aggressive pricing from rivals can pressure your prices
- Currency fluctuations: if you import materials, exchange rates affect your costs
Monitor these factors to anticipate margin changes before they affect your bottom line.
Gross profit margin compared with other metrics
Gross profit margin measures production efficiency, but it's not the only profitability metric you need. Understanding how it relates to operating and net profit margins gives you a complete picture of your financial health.
Gross profit margin vs operating profit margin
Operating profit margin measures profitability after deducting both COGS and operating expenses like rent, utilities, and salaries.
Key differences:
- Gross profit margin: Revenue minus COGS only
- Operating profit margin: Revenue minus COGS and operating expenses
Use operating profit margin to see how efficiently you run your overall business, not just production.
Gross profit margin vs net profit margin
Net profit margin shows your true bottom-line profitability after all expenses, including operating costs, interest, and taxes.
Key differences:
- Gross profit margin: measures production efficiency
- Net profit margin: measures overall business profitability
A business can have a healthy gross margin but a poor net margin if operating costs, debt, or taxes are too high.
How to use each metric
Each margin serves a different purpose in managing your business:
- Use gross profit margin to evaluate pricing decisions and identify which products or services are most profitable
- Use operating profit margin to assess overall operational efficiency and guide budget allocation
- Use net profit margin for long-term financial planning and measuring business resilience
Track all three metrics together for a complete view of your financial health.
How to improve gross profit margin
You can increase your gross profit margin by raising revenue, reducing costs, or both. Here are practical strategies that work for small businesses.
Adjust your prices
Pricing directly affects your margin. Consider these approaches:
- Review prices regularly: update pricing as your costs or market conditions change
- Add value to justify higher prices: improved features, better service, or faster delivery can support premium pricing
- Test price changes: small increases on select products show how customers respond before wider rollouts
- Bundle products or services: packages can increase average transaction value while maintaining perceived value
Monitor how price changes affect both sales volume and overall margin.
Reduce your cost of goods sold
Lowering COGS directly increases your margin. Focus on these areas:
- Negotiate with suppliers: build relationships to secure bulk discounts and better payment terms
- Compare supplier pricing: regularly check if alternative suppliers offer better rates
- Reduce waste: track materials usage to minimise spoilage, errors, or overproduction
- Optimise inventory: avoid overstocking, which ties up cash and risks obsolescence
Even small cost reductions compound over time to significantly improve your margin.
Streamline your operations
Operational efficiency reduces costs without affecting quality. Consider these improvements:
- Automate repetitive tasks: accounting software handles invoicing, reconciliation, and reporting automatically
- Improve inventory management: reduce excess stock to lower storage costs and minimise waste
- Standardise processes: documented workflows reduce errors and training time
- Review regularly: quarterly process audits identify inefficiencies before they become costly
Automation frees up time for higher-value work while reducing the labour component of your COGS.
Track your gross profit margin with Xero
Xero makes it easy to monitor your gross profit margin and other key financial metrics in real time.
With Xero, you can:
- Run profit and loss reports that show your gross margin at a glance
- Track COGS automatically as you record purchases and expenses
- Compare performance across time periods, products, or business areas
- Set up dashboards to monitor margins alongside cash flow and other metrics
Spend less time on calculations and more time growing your business. Get one month free and see how Xero simplifies your financial management.
FAQs on gross profit margin
Here are answers to common questions about gross profit margin.
What is a 25% gross profit margin?
A 25% gross profit margin means you keep $0.25 from every $1 of revenue after paying for direct costs (COGS). The remaining $0.75 covers your cost of goods sold. This is a moderate margin, typical for retail and some manufacturing businesses.
What does a 20% gross profit margin mean?
A 20% gross profit margin means you retain $0.20 of every $1 in revenue as gross profit. While this is on the lower end for many industries, it can be acceptable for high-volume businesses like grocery stores or discount retailers.
How often should I calculate my gross profit margin?
Calculate your gross profit margin monthly at minimum. Review it more frequently during periods of growth, cost changes, or market shifts. Quarterly deep dives help you compare performance against benchmarks.
Can gross profit margin be negative?
Yes, gross profit margin can be negative when your cost of goods sold exceeds your revenue. This means you're losing money on every sale and signals a serious problem requiring immediate action, such as raising prices or reducing production costs.
What's the difference between gross profit margin and markup?
Markup is the percentage added to your cost to set a selling price. Gross profit margin is the percentage of the selling price that becomes profit. For example, a 50% markup on a $10 item creates a $15 price, but the gross profit margin is only 33% ($5 profit ÷ $15 price).
Disclaimer
Xero does not provide accounting, tax, business or legal advice. This guide has been provided for information purposes only. You should consult your own professional advisors for advice directly relating to your business or before taking action in relation to any of the content provided.