ADVERTISEMENT
  • About
  • Advertise
  • Privacy & Policy
  • Contact
Office Learner
ADVERTISEMENT
  • Home
  • Browse by Category
    • Word
      • Word Basics
      • Word Data Entry
      • Word Formatting
      • Word Templates
      • Word Tips
    • Excel
      • Excel Basics
      • Excel Shortcuts
      • Excel Charts
      • Data Validation
      • Conditional Formatting
      • Data Analysis with Excel
      • Dynamic Arrays
      • Advanced Excel Topics
      • Developing Excel Related Tools
      • Essential Excel Books
      • Excel for Accountants
      • Excel for Finance
      • Excel Functions and Formulas
      • Excel Pivot Tables
      • Excel Power BI
      • Excel Power Query
      • Excel Templates
      • Excel Training & Courses
      • Macros and Excel VBA
    • PowerPoint
      • Animation
      • PowerPoint Basics
      • PowerPoint Templates
  • About
  • Office Books
  • Courses
No Result
View All Result
  • Home
  • Browse by Category
    • Word
      • Word Basics
      • Word Data Entry
      • Word Formatting
      • Word Templates
      • Word Tips
    • Excel
      • Excel Basics
      • Excel Shortcuts
      • Excel Charts
      • Data Validation
      • Conditional Formatting
      • Data Analysis with Excel
      • Dynamic Arrays
      • Advanced Excel Topics
      • Developing Excel Related Tools
      • Essential Excel Books
      • Excel for Accountants
      • Excel for Finance
      • Excel Functions and Formulas
      • Excel Pivot Tables
      • Excel Power BI
      • Excel Power Query
      • Excel Templates
      • Excel Training & Courses
      • Macros and Excel VBA
    • PowerPoint
      • Animation
      • PowerPoint Basics
      • PowerPoint Templates
  • About
  • Office Books
  • Courses
No Result
View All Result
Office Learner
No Result
View All Result
Home Excel

Excel STOCKHISTORY Function in 2026: Pull Live Historical Financial Data Into Any Spreadsheet

Tanjila Rashid by Tanjila Rashid
June 8, 2026
in Excel
0
Excel STOCKHISTORY Function in 2026: Pull Live Historical Financial Data Into Any Spreadsheet
0
SHARES
0
VIEWS
Share on FacebookShare on Twitter

Excel STOCKHISTORY Function in 2026: Pull Live Historical Financial Data Into Any Spreadsheet

Published: June 8, 2026

For years, getting historical stock prices into an Excel spreadsheet meant exporting CSV files from financial websites, cleaning them up, and hoping the data was accurate. Not anymore. The STOCKHISTORY function, available in Microsoft 365, pulls real-time historical stock price data directly into your spreadsheet — no API key, no web scraping, no manual imports. In this guide, you will learn exactly how STOCKHISTORY works, how to use it to build everything from simple price lookups to sophisticated multi-stock performance dashboards, and what its limitations are so you can plan around them.

What Is the STOCKHISTORY Function?

STOCKHISTORY is a dynamic array function that returns a table of historical price data for a financial instrument — stocks, ETFs, mutual funds, and currencies. It uses the same data source as Excel's built-in Stocks data type (powered by Refinitiv / LSEG) and spills its results into as many rows and columns as needed.

The basic syntax is:

=STOCKHISTORY(stock, start_date, [end_date], [interval], [headers], [property0], [property1], …)

Arguments:

stock: The ticker symbol as a text string, e.g. "MSFT" or a cell reference containing the ticker.

ADVERTISEMENT

start_date: The first date in the range. Can be a date value, cell reference, or date formula.

end_date (optional): The last date. Defaults to the current date if omitted.

interval (optional): 0 = daily (default), 1 = weekly, 2 = monthly.

headers (optional): 0 = no headers, 1 = date headers (default), 2 = stock code + date headers.

property0, property1, … (optional): Which price fields to return: 0=Date, 1=Close, 2=Open, 3=High, 4=Low, 5=Volume.

Basic Examples to Get Started

Example 1: Last 30 Days of Microsoft Closing Prices

=STOCKHISTORY("MSFT", TODAY()-30, TODAY(), 0, 1, 0, 1)

This returns a two-column spill range: Date and Close Price for every trading day in the past 30 days. The function automatically skips weekends and market holidays.

Example 2: Full OHLCV Data for a Custom Date Range

=STOCKHISTORY("AAPL", "2026-01-01", "2026-03-31", 0, 1, 0, 1, 2, 3, 4, 5)

Returns all six columns — Date, Close, Open, High, Low, Volume — for Apple stock for Q1 2026.

Example 3: Monthly Prices for the Past Year

=STOCKHISTORY(A2, DATE(2025,6,1), TODAY(), 2, 1, 0, 1)

Where A2 contains a ticker symbol. Returns monthly close prices, useful for building year-on-year performance charts.

Property Reference Table

Here is a quick reference for the property numbers used in STOCKHISTORY:

If you omit all property arguments, STOCKHISTORY defaults to returning just Date (0) and Close (1).

Building a Multi-Stock Comparison Dashboard

One of the most powerful uses of STOCKHISTORY is comparing the performance of multiple stocks over the same time period. Here is a simple structure to build this in Excel:

Set up a header row with your ticker symbols in B1, C1, D1, etc. (e.g., MSFT, AAPL, GOOGL).

In A2 enter your start date. In A3, use =STOCKHISTORY(B$1, $A$2, TODAY(), 2, 0, 0) to get the monthly dates from the first ticker.

In B3, enter: =STOCKHISTORY(B$1, $A$2, TODAY(), 2, 0, 1) for close prices — this returns only prices without the date column (dates are already in column A).

Copy B3 to C3, D3, etc. Each column automatically pulls data for the ticker in its header row.

Add an index column to show percentage return from the start date: =B3/B$3-1. Format as percentage.

Insert a line chart using the index columns to create a clean percentage-return comparison chart.

Currency and Exchange Rate Data

STOCKHISTORY is not limited to equities. You can retrieve historical currency exchange rate data using standard forex pair notation. For example:

=STOCKHISTORY("USD/EUR", DATE(2026,1,1), TODAY(), 2, 1, 0, 1)

This returns monthly USD-to-EUR exchange rates since January 2026. The same function works for GBP/USD, JPY/USD, and most major currency pairs. This is extremely useful for finance teams doing foreign exchange exposure analysis or converting historical revenues to a base currency.

Limitations to Be Aware Of

Microsoft 365 subscription required. STOCKHISTORY is not available in Excel 2019 or older perpetual licences.

Data is delayed. Prices are not real-time. The data is typically delayed by 15-20 minutes for intraday, and historical data may have a 24-hour lag for the most recent trading day.

No intraday granularity. The minimum interval is daily (interval = 0). Hourly or minute-by-minute data is not available.

Spill range conflicts. Because STOCKHISTORY returns a spill range, ensure there are enough empty cells below and to the right of your formula. If another value blocks the spill, Excel returns a #SPILL! error.

Internet connection required. The function calls a live data service. Without an internet connection, or if the Refinitiv/LSEG service is temporarily unavailable, STOCKHISTORY returns a #GETTING_DATA or #VALUE! error.

Limited historical depth. Most tickers support up to 20 years of daily history. Some less-traded instruments may have shorter histories available.

Conclusion: Professional Financial Analysis Without Leaving Excel

STOCKHISTORY removes one of the most tedious tasks in financial analysis: sourcing and cleaning historical price data. With a single formula, you have clean, structured data ready for analysis, charting, and modelling. Combined with Excel's dynamic array engine, it becomes the foundation for multi-stock dashboards, performance attribution models, and currency analysis workbooks that update automatically every time you open them.

Try it now: In any Microsoft 365 Excel workbook, type =STOCKHISTORY("MSFT", TODAY()-90) in an empty cell and press Enter. Watch as 90 days of Microsoft stock history appears automatically. From there, the analysis possibilities are unlimited.

Tags: Excel 2026excel financial dataexcel stockhistoryhistorical stock datastockhistory function
ADVERTISEMENT
Previous Post

PowerPoint Recording Studio in 2026: Record, Narrate, and Share Presentation Videos

Next Post

Outlook Inbox Sweep with Copilot in 2026: Declutter, Unsubscribe, and Archive at AI Speed

Tanjila Rashid

Tanjila Rashid

Next Post
Outlook Inbox Sweep with Copilot in 2026: Declutter, Unsubscribe, and Archive at AI Speed

Outlook Inbox Sweep with Copilot in 2026: Declutter, Unsubscribe, and Archive at AI Speed

ADVERTISEMENT
  • Trending
  • Comments
  • Latest
The Evolution of Microsoft Word: A Brief History

The Evolution of Microsoft Word: A Brief History

May 27, 2026

How to Merge and Center Selected Cells in Excel (4 Ways)

May 27, 2026

How to Create a Weighted Sales Pipeline in Excel

May 27, 2026
How to Use Excel SUMIF to Sum Values Greater Than 0

How to Merge Cells in Excel Without Merging Actually

May 27, 2026
Spreadsheet Layout

What is spreadsheet? and how it works!

0
Spreadsheet Layout

Spreadsheet Layout

0
Spreadsheet Layout

IF function of Google Sheets – usage and formula examples

0

5 Google Sheets tricks that you always need!

0
Outlook Inbox Sweep with Copilot in 2026: Declutter, Unsubscribe, and Archive at AI Speed

Outlook Inbox Sweep with Copilot in 2026: Declutter, Unsubscribe, and Archive at AI Speed

June 8, 2026
Excel STOCKHISTORY Function in 2026: Pull Live Historical Financial Data Into Any Spreadsheet

Excel STOCKHISTORY Function in 2026: Pull Live Historical Financial Data Into Any Spreadsheet

June 8, 2026
PowerPoint Recording Studio in 2026: Record, Narrate, and Share Presentation Videos

PowerPoint Recording Studio in 2026: Record, Narrate, and Share Presentation Videos

June 8, 2026
Excel Name Manager Mastery in 2026: Organize Complex Formulas and Ranges Like a Pro

Excel Name Manager Mastery in 2026: Organize Complex Formulas and Ranges Like a Pro

June 8, 2026

Recent News

Outlook Inbox Sweep with Copilot in 2026: Declutter, Unsubscribe, and Archive at AI Speed

Outlook Inbox Sweep with Copilot in 2026: Declutter, Unsubscribe, and Archive at AI Speed

June 8, 2026
Excel STOCKHISTORY Function in 2026: Pull Live Historical Financial Data Into Any Spreadsheet

Excel STOCKHISTORY Function in 2026: Pull Live Historical Financial Data Into Any Spreadsheet

June 8, 2026
PowerPoint Recording Studio in 2026: Record, Narrate, and Share Presentation Videos

PowerPoint Recording Studio in 2026: Record, Narrate, and Share Presentation Videos

June 8, 2026
Excel Name Manager Mastery in 2026: Organize Complex Formulas and Ranges Like a Pro

Excel Name Manager Mastery in 2026: Organize Complex Formulas and Ranges Like a Pro

June 8, 2026
Office Learner

OfficeLearner is a place where you can learn PowerPoint, Excel, Word Data Analysis, and other Office related programs. We provide tips, how to guide and also provide Excel solutions to your business problems

Follow Us

DMCA.com Protection Status

Browse by Category

  • Clipchamp
  • Excel
  • Google Sheets
  • Microsoft 365
  • Microsoft Copilot
  • Microsoft Designer
  • Microsoft Forms
  • Microsoft Loop
  • Microsoft Sway
  • Microsoft Teams
  • Microsoft Viva
  • OneDrive
  • OneNote
  • Outlook
  • Planner
  • Power Automate
  • Power BI
  • PowerPoint
  • SharePoint
  • Teams
  • Word

Recent News

Outlook Inbox Sweep with Copilot in 2026: Declutter, Unsubscribe, and Archive at AI Speed

Outlook Inbox Sweep with Copilot in 2026: Declutter, Unsubscribe, and Archive at AI Speed

June 8, 2026
Excel STOCKHISTORY Function in 2026: Pull Live Historical Financial Data Into Any Spreadsheet

Excel STOCKHISTORY Function in 2026: Pull Live Historical Financial Data Into Any Spreadsheet

June 8, 2026
  • About
  • Advertise
  • Privacy & Policy
  • Contact

© 2022 OfficeLearner - Free Excel, PowerPoint & Word Tutorial & Online Courses

No Result
View All Result

© 2022 OfficeLearner - Free Excel, PowerPoint & Word Tutorial & Online Courses

This website uses cookies. By continuing to use this website you are giving consent to cookies being used. Visit our Privacy and Cookie Policy.