The Google Finance API for stock quotes as JSON

Get a Google Finance quote as JSON for any ticker, or leave the query out for a market overview. Read the price and the previous close from one response.

Google Finance API at a glance

This API returns a Google Finance quote as JSON. Send a POST request with a ticker in query, or omit query for the overview. Run the example below to see the exact shape.

Endpoint
POST /v1/data/google/finance
Authentication
API key as Authorization: Bearer wh_…
Stage
Stable
Output for a ticker
Name, exchange, price, price_movement, currency, previous_close and a news array
Output for the overview
A markets object grouped into US, Europe, Asia, Latin America, Currencies, Crypto and Futures
Ticker format
Symbol and exchange such as AAPL:NASDAQ, or a pair such as BTC-USD
Locale controls
language and country
Query length
Up to 100 characters. Omit query for the market overview.
Credit weight
1. See the pricing page for current rates.

One request, structured JSON.

This request asks for one quote, using the AAPL:NASDAQ ticker. The response below is trimmed to two news items. Copy the request to try it yourself.

POST /v1/data/google/finance
curl -X POST "https://api.datablue.dev/v1/data/google/finance" \
  -H "Authorization: Bearer wh_..." \
  -H "Content-Type: application/json" \
  -d '{
    "query": "AAPL:NASDAQ"
  }'
Response (trimmed to 2 news items)
{
  "success": true,
  "time_taken": 0.759,
  "stock": "AAPL:NASDAQ",
  "exchange": "NASDAQ",
  "name": "Apple Inc",
  "price": "$342.56",
  "price_movement": { "percentage": "-1.90%", "value": "-$6.65", "movement": "down" },
  "currency": "USD",
  "previous_close": "$349.21",
  "after_hours_price": "$344.87",
  "after_hours_movement": { "percentage": "+0.67%", "value": "+$2.31", "movement": "up" },
  "news": [
    {
      "title": "Michael Burry Halves SMH, Nvidia Puts but Keeps Nasdaq 100 Bet",
      "url": "https://www.benzinga.com/etfs/sector-etfs/26/11/63506413/michael-burry-halves-smh-nvidia-puts-but-keeps-nasdaq-100-bet?utm_source=googlefinance",
      "source": "Benzinga",
      "snippet": "Michael Burry cut his bearish bets on SMH and Nvidia by half but holds his April 2027 Nasdaq 100 puts. What does it mean for chip and tech ETFs?"
    },
    {
      "title": "Intuit Stock Tumbles After Earnings Beat. It’s Selling Mailchimp.",
      "url": "https://www.barrons.com/articles/intuit-earnings-stock-price-50cb5c01?mod=goog_fin_scbar",
      "source": "News Corp",
      "snippet": "Intuit reports better-than-expected fiscal first-quarter earnings."
    }
  ]
}

What a quote returns.

A ticker quote arrives as one object with named fields.

Identity

The stock field echoes the ticker you sent. The name field holds the company name. The exchange field holds the listing venue. Match them to your own security records.

Price

Price arrives as display text, symbol included. Strip the symbol and any commas before you do math.

Daily change

The price_movement object holds a percentage and a value. Its movement field reads up or down. Read movement instead of parsing the sign.

Previous close

The previous_close field gives the prior close as display text. Compare it with price to check a move yourself.

After hours

The sample ticker also returned after_hours_price and after_hours_movement. Treat both as optional in your code. Check for them before you read them.

News

A ticker response carries a news array. Each item holds a title and a url. It also holds a source and a snippet.

Market overview

The markets object groups rows by region and asset type. Rows hold a stock id and a Google Finance link. They also hold a name and a price. Loop over the groups to build a market board.

Options that shape your request.

Every field is optional, so an empty body returns the market overview of global indexes. Add a ticker in query when you want one quote.

Ticker query

Set query to a ticker such as AAPL:NASDAQ or BTC-USD. The value runs up to 100 characters. Use the symbol and exchange format from Google Finance.

Language and country

Pass language for the hl code and country for the gl code of the request. Country has no default, while language defaults to en. Test a locale against the market overview before you rely on it in a production system.

Market overview

Omit query when you want the market overview. The response then holds a markets object. No single quote fields appear in that case. Run it once to see the groups for yourself.

What teams build with it.

Quotes feed watchlists and price alerts in your own tools.

Watchlists

Loop over your tickers and send one request for each. Store the price and previous_close for every symbol.

Market boards

Call the overview with no query to fill a dashboard. Refresh it on a schedule that suits your readers.

Price alerts

Read price_movement on every quote you fetch. Alert your team when the percentage crosses a threshold.

Ticker news

Show news items beside each quote on your own page. Pair each headline with the url returned for it.

Why use an API instead of scraping Finance yourself.

One endpoint covers a quote lookup and a market overview. A ticker in query returns a quote with news, while an empty body returns the overview. You pick the job by what you put in query.

Prices arrive as display strings, so your code must parse them into numbers before any math. Strip the symbol and the commas, then convert. Keep the original string beside the number for audits.

Every field on this page appears in a live response. Quotes and news change by the minute, so your numbers will differ from our sample. Run a call of your own to see current values.

Your first Finance quote in a minute.

Sign up, get a key and run one quote.

  1. Create an account

    Sign up to get your API key.

  2. Send a ticker

    POST a ticker to /v1/data/google/finance with a Bearer key. Omit query when you want the market overview instead.

  3. Read the quote

    Read price and price_movement straight off the response object. Pair each price with its currency field whenever the response includes one for that row.

Google Finance API questions.

Short answers about data and billing before you start.

It returns a quote for one ticker as JSON. Omit the query and you get a market overview instead.

Send a POST request to /v1/data/google/finance with a ticker in query and your Bearer key. Use the symbol and exchange format such as AAPL:NASDAQ.

A quote carries a name and an exchange. It also carries a price and a previous close. A news array rides along with the quote. Compare the fields above with the sample response.

The overview returns a markets object grouped into regions and asset types in one call. Each group lists five rows in our sample. Each row has a price and a previous close.

Our live responses held a current quote and news. We saw no price history in them, so build around current quotes only for now.

Price fields arrive as display text with symbols and commas. Strip them before you convert to numbers. Keep the currency field beside each value.

Pass language for the hl code and country for the gl code of the request. Country has no default, while language defaults to en.

This API is marked stable in the catalogue. Pin your code to the documented fields and read the changelog before every upgrade you ship.

This API has a credit weight of 1. Check the pricing page for current rates.

Pull a Google Finance quote in a minute.

Create an account to get your key. Then run the example with AAPL:NASDAQ or an empty body.

Start free