Gross Profit (Historical)

Returns historical gross profit for a company. Gross profit is the profit remaining after subtracting the cost of revenue from total revenue.

What is Gross Profit?

Gross Profit = Revenue - Cost of Revenue

It measures how efficiently a company produces its goods or services before accounting for operating expenses, interest, and taxes.

Parameters

Parameter Required Description
Symbol Yes Stock ticker symbol
Year Yes Fiscal year (e.g., 2023) or period code (lq, ly)
Quarter No Quarter number 1-4 (default: 1)
TTM No Set to "TTM" for trailing twelve months

Period Codes

Code Meaning
lq Last quarter
lq-1 Two quarters ago
ly Last year
ly-1 Two years ago

Examples

=hf_Gross_Profit("AAPL", "2023", "4")
Q4 2023 gross profit
=hf_Gross_Profit("MSFT", "2023", "3")
Q3 2023 gross profit
=hf_Gross_Profit("AAPL", "lq")
Last quarter gross profit
=hf_Gross_Profit("GOOGL", "2023", "4", "TTM")
TTM gross profit
=hf_Gross_Profit(A1, B1, C1)
Cell references

When to Use

  • Analyzing profitability trends
  • Calculating gross margin
  • Building financial models
  • Comparing operational efficiency
  • Evaluating pricing power

When NOT to Use

Scenario Use Instead
Need current gross profit GrossProfit()
Need gross margin % GrossMargin()
Need operating profit hf_Operating_Income()
Need EBIT hf_Earning_Before_Interest_and_Taxes()
Need net income hf_Net_Income()

Common Issues & FAQ

Q: Why am I getting "NA"? A: Check that:

  • The symbol is valid and has fundamental data available
  • The year/quarter combination exists in the data
  • The company has reported financials for that period

Q: How do I calculate gross margin percentage? A: Divide gross profit by revenue: =hf_Gross_Profit("AAPL", "2023", "4") / hf_Revenue("AAPL", "2023", "4")

Q: What's the difference between gross profit and operating income? A: Operating income = Gross Profit - Operating Expenses (SG&A, R&D, etc.)

Get Access to 1 Billion Usable Market data points IN YOUR EXCEL SHEETS WITH EASY TO USE EXCEL FUNCTIONS

Get started today
MarketXLS Excel Add-in Tutorial - How to Use Gross Profit (Historical) and Other Financial Formulas
How does MarketXLS work?