Required Datapoints
- Revenue: Total income generated from sales of a product, service, or business unit.
- Cost of Goods Sold (COGS): Direct costs of producing or delivering the product or service, such as materials, labor, and manufacturing expenses.
Gross Margin measures the profitability of a product, service, or business by calculating the percentage of revenue that remains after deducting the Cost of Goods Sold (COGS). It represents the portion of sales revenue that contributes to covering operational expenses and generating profit.
Gross Margin is a key indicator of financial health and cost-efficiency, reflecting how effectively revenue is converted into profit after direct costs like COGS or service delivery.
The relevance and interpretation of this metric shift depending on the model or product:
A high gross margin signals efficient operations and pricing power, while a low or declining margin highlights cost control issues or underpricing.
By analyzing margins by segment, product line, or geography, you can improve pricing models, vendor negotiations, and profitability forecasting.
Gross Margin informs:
These are the main factors that directly impact the metric. Understanding these lets you know what levers you can pull to improve the outcome
Actionable ideas to optimize this KPI, from fast, low-effort wins to strategic initiatives that drive measurable impact.
Activities commonly tied to improving or operationalizing this KPI.
| Activity | Description |
|---|---|
| Revenue Management | Revenue Management is a strategic process focused on maximizing an organization’s income by aligning pricing, packaging, customer segmentation, and sales or channel tactics with market demand, competitive positioning, and overarching business objectives. It makes the motion operational through ownership, routines, and cross-functional follow-through. Relevant KPIs include Cost to Serve and Customer Lifetime Value. |
| Pricing Strategy | Pricing Strategy is an iterative process focused on defining, testing, and optimizing how a product or service is priced, packaged, and positioned to maximize customer adoption, revenue, and market competitiveness. It gives teams a clear plan for where to focus, how to sequence work, and what to measure. Relevant KPIs include Average Contract Value and Average Revenue Per Expansion Account. |
| Cost Optimization | Cost Optimization involves the continuous process of strategically monitoring, controlling, and optimizing expenses to maximize value and efficiency throughout the customer lifecycle. It improves performance by removing friction, testing changes, and scaling what works. Relevant KPIs include Gross Margin and Net Profit Margin. |
A software company calculates its gross margin for Q3:
This KPI is associated with the following stages in the AAARRR (Pirate Metrics) funnel:
This KPI is classified as a lagging Indicator. It reflects the results of past actions or behaviors and is used to validate performance or assess the impact of previous strategies.
This role is directly accountable for the KPI and is expected to drive progress and decisions around it.
These roles contribute directly to performance and typically partner on execution, reporting, or optimization.
These leading indicators influence this KPI and act as early signals that forecast future changes in this KPI.
These lagging indicators confirm, quantify, or amplify this KPI and help explain the broader business impact on this KPI after the fact.
How this KPI is structured in Cube.js, including its key measures, dimensions, and calculation logic for consistent reporting.
cube('Sales', { sql: `SELECT * FROM sales`, measures: { revenue: { sql: `revenue`, type: 'sum', title: 'Revenue', description: 'Total income generated from sales of a product, service, or business unit.' }, cogs: { sql: `cogs`, type: 'sum', title: 'Cost of Goods Sold', description: 'Direct costs of producing or delivering the product or service, such as materials, labor, and manufacturing expenses.' }, grossMargin: { sql: `(${revenue} - ${cogs}) / ${revenue} * 100`, type: 'number', title: 'Gross Margin', description: 'Gross Margin measures the profitability of a product, service, or business by calculating the percentage of revenue that remains after deducting the Cost of Goods Sold (COGS).' } }, dimensions: { id: { sql: `id`, type: 'string', primaryKey: true, title: 'ID', description: 'Unique identifier for each sales record.' }, saleDate: { sql: `sale_date`, type: 'time', title: 'Sale Date', description: 'The date when the sale was made.' } }})Note: This is a reference implementation and should be used as a starting point. You’ll need to adapt it to match your own data model and schema