The Scenario
Tax season is three weeks out and your client — a high-net-worth individual with 20 dividend-paying positions — has handed you a Google Sheet with tickers in column A and cost basis in column B. You need the full dividend history for each position, with split adjustment factors, to calculate adjusted cost basis. The brokerage statement has the cash numbers but not the corporate actions. You need both.
The bad version:
- You look up each ticker on a financial data aggregator, find the dividend history section, and start copying ex-dates, pay dates, and cash amounts per share into rows in the sheet.
- Halfway through you realize three of the tickers had stock splits during the holding period and you need to find and apply split adjustment factors separately — another lookup, another tab, another manual reconciliation.
- By the time you've done 20 tickers with dividends averaging 8 payments each, you've manually entered 160 rows and you're not fully confident the split factors are applied in the right sequence.
This is the kind of work that creates errors under time pressure, and this client's return goes to review before it goes out.
The Easy Way: One Prompt in SheetXAI
SheetXAI is an AI agent that lives inside your Google Sheet. It reads the ticker list, calls the Polygon.io dividends and splits APIs for each position, and writes the full history into a structured tab — including ex-dates, pay dates, cash amounts, and split adjustment factors.
For each ticker in column A, fetch the dividend history from Polygon.io including ex-date, pay date, cash amount per share, and split adjustment factor, writing the results into a "Dividend History" sheet.
What You Get
- A "Dividend History" tab with one row per dividend event per ticker.
- Columns: Ticker, Ex-Date, Pay Date, Cash Amount Per Share, Split Adjustment Factor.
- Rows sorted by ex-date descending within each ticker group.
- If a ticker has no dividend history in the Polygon.io database, a single row is written with "No dividends on record" so you know it was checked, not skipped.
What If the Data Is Not Quite Ready
I only need dividends from the last 12 months, not the full history
Get all dividend payments from Polygon.io for the tickers in column A for the last 12 months and write the ticker, ex-date, and dividend amount per share into rows sorted by ex-date descending.
Some tickers are in the sheet as full company names, not symbols
The tickers in column A are a mix of stock symbols and full company names. For entries that look like company names rather than ticker symbols, try to resolve them to a ticker before fetching the dividend history from Polygon.io. Write all dividend history into a "Dividend History" tab. Flag any entries you could not resolve.
I need the split history as a separate tab to calculate pre-split cost basis
For each ticker in column A, fetch the dividend history from Polygon.io and write it into a "Dividends" tab. Then separately fetch the stock split history for each ticker and write split date, split ratio, and old-to-new share conversion into a "Splits" tab. Keep both tabs linked by ticker symbol.
Pull dividend history, apply split factors to get split-adjusted dividend per share, and calculate total dividend income per position based on my share count
For each ticker in column A, fetch the full dividend and split history from Polygon.io. Apply split adjustment factors to each dividend to get the split-adjusted cash amount per share. Multiply by the share count in column B to get total dividend income per payment. Write adjusted dividend per share and total dividend income into columns D and E of the "Dividend History" tab.
One instruction covers the data pull, the adjustment calculation, and the per-position income figure.
Try It
Open your portfolio Google Sheet and Get the 7-day free trial of SheetXAI. Ask it to fetch the complete dividend and split history from Polygon.io for each position and write it into a tax-ready layout. For full corporate event history including ticker renames, see the spoke on pulling corporate event history. For the full partner overview, see the Polygon.io hub.
