     [Blog](https://scrapfly.io/blog)   /  [api](https://scrapfly.io/blog/tag/api)   /  [Google Finance API and the Best Alternatives for Developers (2026)](https://scrapfly.io/blog/posts/guide-to-google-finance-api)   # Google Finance API and the Best Alternatives for Developers (2026)

 by [Ziad Shamndy](https://scrapfly.io/blog/author/ziad) Jul 24, 2026 14 min read [\#api](https://scrapfly.io/blog/tag/api) 

 [  ](https://www.linkedin.com/sharing/share-offsite/?url=https%3A%2F%2Fscrapfly.io%2Fblog%2Fposts%2Fguide-to-google-finance-api "Share on LinkedIn") [  ](https://x.com/intent/tweet?url=https%3A%2F%2Fscrapfly.io%2Fblog%2Fposts%2Fguide-to-google-finance-api&text=Google%20Finance%20API%20and%20the%20Best%20Alternatives%20for%20Developers%20%282026%29 "Share on X") [  ](https://www.facebook.com/sharer/sharer.php?u=https%3A%2F%2Fscrapfly.io%2Fblog%2Fposts%2Fguide-to-google-finance-api "Share on Facebook")    

 

 

Summarize this article with

 [  ](https://chat.openai.com/?q=Summarize%20this%20article%20and%20explain%20how%20Scrapfly%20helps%20me%20scrape%20any%20website%20at%20scale%20and%20bypass%20anti-bot%20systems%20for%20my%20use%20case%3A%20https%3A%2F%2Fscrapfly.io%2Fblog%2Fposts%2Fguide-to-google-finance-api) [  ](https://claude.ai/new?q=Summarize%20this%20article%20and%20explain%20how%20Scrapfly%20helps%20me%20scrape%20any%20website%20at%20scale%20and%20bypass%20anti-bot%20systems%20for%20my%20use%20case%3A%20https%3A%2F%2Fscrapfly.io%2Fblog%2Fposts%2Fguide-to-google-finance-api) [  ](https://x.com/i/grok?text=Summarize%20this%20article%20and%20explain%20how%20Scrapfly%20helps%20me%20scrape%20any%20website%20at%20scale%20and%20bypass%20anti-bot%20systems%20for%20my%20use%20case%3A%20https%3A%2F%2Fscrapfly.io%2Fblog%2Fposts%2Fguide-to-google-finance-api) [  ](https://www.perplexity.ai/search/new?q=Summarize%20this%20article%20and%20explain%20how%20Scrapfly%20helps%20me%20scrape%20any%20website%20at%20scale%20and%20bypass%20anti-bot%20systems%20for%20my%20use%20case%3A%20https%3A%2F%2Fscrapfly.io%2Fblog%2Fposts%2Fguide-to-google-finance-api) [  ](https://www.google.com/search?udm=50&aep=11&q=Summarize%20this%20article%20and%20explain%20how%20Scrapfly%20helps%20me%20scrape%20any%20website%20at%20scale%20and%20bypass%20anti-bot%20systems%20for%20my%20use%20case%3A%20https%3A%2F%2Fscrapfly.io%2Fblog%2Fposts%2Fguide-to-google-finance-api) 



   

The Google Finance API has been dead for over a decade, but the search demand never left. Developers still need that data, they just need a new way to get it.

This guide covers the three real paths that still work today, the GOOGLEFINANCE function in Google Sheets, named API alternatives worth knowing, and scraping the live Google Finance page when you need more control.

## Key Takeaways

Learn the real paths to Google Finance data now that the original API is gone, from the free GOOGLEFINANCE function to named API alternatives and direct scraping.

- The Google Finance API was deprecated in 2011 and shut down in 2012, so there is no official API left to integrate against
- The GOOGLEFINANCE function in Google Sheets is the closest free, no-key path to live stock data, and can be bridged into Python with gspread
- Named data providers like Alpha Vantage, Twelve Data, Polygon.io, Finnhub, Tiingo, and Nasdaq Data Link fill the gap the old API left, each with a different free-tier tradeoff
- Scraping the live Google Finance page still works with Python, requests, and BeautifulSoup, though the CSS classes rotate often and selectors need upkeep
- Scrapfly handles the anti-bot protection and proxy rotation that raw scrapers run into once you scale past a handful of requests

**Get web scraping tips in your inbox**Trusted by 100K+ developers and 30K+ enterprises. Unsubscribe anytime.







## Is the Google Finance API Discontinued?

Yes. Google deprecated the Finance API on May 26, 2011, and shut it down on October 20, 2012, as [confirmed in Google's own announcement](https://groups.google.com/g/google-finance-apis/c/q-DbjbzQDGQ). The consumer-facing Google Finance site lasted longer, but lost most of its portfolio and community features when Google stripped it down around 2017 and 2018.

For developers today, this means there is no drop-in API to call for Google Finance data, official or unofficial. Anyone who bookmarked the old API docs or still has code pointed at a `finance.google.com/finance/info` style endpoint will find it dead, not just deprecated. What is left are three practical paths:

- The free GOOGLEFINANCE function inside Google Sheets
- Named third-party data APIs like Alpha Vantage and Polygon.io
- Scraping the live Google Finance page directly

The rest of this guide walks through each one, starting with the Sheets function since it needs no API key to get running.



## Using the GOOGLEFINANCE Function in Google Sheets

The closest free, no-key path to Google Finance data is the built-in [GOOGLEFINANCE](https://support.google.com/docs/answer/3093281?hl=en) function in Google Sheets. It fetches real-time and historical stock data straight into a spreadsheet cell, and with a bit of glue code you can pull those values into Python as well.



Here are some examples of how to use this function within Google Sheets:

| Function Example | Description |
|---|---|
| `=GOOGLEFINANCE("AAPL", "price")` | Returns the current price of Apple stock |
| `=GOOGLEFINANCE("GOOGL", "priceopen")` | Fetches the opening price for Google stock |
| `=GOOGLEFINANCE("NVDA", "high")` | Retrieves the daily high for NVIDIA stock |
| `=GOOGLEFINANCE("AAPL", "all", DATE(2022,1,1), DATE(2023,1,1), "DAILY")` | Provides daily historical data for Apple between specified dates |

You can retrieve data from your Google Sheet and integrate it into Python applications. Create a formula in a Google Sheet, and read the result back once the cell updates, using the Python [gspread](https://pypi.org/project/gspread/) package:

python```python
# to start:
# pip install gspread
import gspread
import time

# JSON credentials for google service account
# see docs: https://cloud.google.com/iam/docs/service-account-overview
AUTH_FILE = './google-service.auth.json'

def get_stock_price_from_googlefinance(sheet_id, ticker):
    """
    Adds a formula to a Google Sheet to get the stock price using GOOGLEFINANCE.

    Parameters:
        sheet_id (str): The ID of the Google Sheet.
        ticker (str): The stock ticker symbol.

    Returns:
        float: The current stock price.
    """
    # Authenticate with Google Sheets
    gc = gspread.service_account(filename=AUTH_FILE)
    worksheet = gc.open_by_key(sheet_id).sheet1  # Use the first sheet

    # Add the GOOGLEFINANCE formula to a specific cell
    cell = 'A1'
    worksheet.update(
        range_name=cell,
        values=[[f'=GOOGLEFINANCE("{ticker}", "price")']],
        value_input_option='USER_ENTERED',  # required to load formula
    )

    # Wait for the formula to calculate
    for _ in range(10):  # Retry for up to 10 seconds
        value = worksheet.acell(cell).value
        try:
            return float(value)  # Convert to float if valid
        except (ValueError, TypeError):
            time.sleep(1)

    raise TimeoutError("Failed to retrieve the stock price from Google Sheets.")

# Example usage
# Note: Spreadsheet ID can be found in the URL:
# https://docs.google.com/spreadsheets/d/1dCFlfNrijRSgpKczw06OCD82_OPeJctJnBe9w9SAKyo/edit?gid=0#gid=0
sheet_id = "1dCFlfNrijRSgpKczw06OCD82_OPeJctJnBe9w9SAKyo"
ticker = "NVDA"
price = get_stock_price_from_googlefinance(sheet_id, ticker)
print(f"The current price of {ticker} is {price}.")
# will print:
"The current price of NVDA is 141.98."
```



This works, but it is not the most efficient way to get this data. It is slow, rate limited, and not built for real-time or large-scale use. For heavier workloads, a dedicated data API or direct scraping is the better path. Let's look at the named API alternatives first, then scraping the live page.



## API Alternatives to Google Finance Data

There is no direct replacement for the old Google Finance API, but a handful of data providers cover the same ground and then some. Here is how the main ones stack up:

| Source | Best for | Free tier | Access method |
|---|---|---|---|
| [yfinance](https://pypi.org/project/yfinance/) (via Yahoo Finance) | Free Python convenience for historical and current data | Free, no key required | Python library |
| [Alpha Vantage](https://www.alphavantage.co/) | Reliable daily data and technical indicators | Free tier, keyed, around 25 requests per day | REST API key |
| [Twelve Data](https://twelvedata.com/) | Real-time stocks and forex time series | Free tier, keyed, around 800 requests per day | REST API key |
| [Polygon.io](https://polygon.io/) | Clean real-time and historical market data | Limited free tier, end-of-day data only | REST API key |
| [Finnhub](https://finnhub.io/) | Generous free tier, quotes, news, fundamentals | Free tier, keyed, around 60 requests per minute | REST API / WebSocket |
| [Tiingo](https://www.tiingo.com/) | Clean end-of-day data and fundamentals | Free tier for personal use | REST API key |
| [Nasdaq Data Link](https://data.nasdaq.com/) | Fundamentals, macro, and alternative datasets | Free and paid datasets | REST API key |

For quick Python scripts and personal projects, `yfinance` is the easiest starting point since it needs no API key at all. You can learn more about that path in our dedicated article:

[Yahoo Finance API: How to Get Yahoo Finance Data in Python (2026)Get Yahoo Finance data in Python with the yfinance library, the direct chart endpoint, and scraping, plus how to keep it running at scale.](https://scrapfly.io/blog/posts/guide-to-yahoo-finance-api)

Picking between the keyed APIs comes down to what you need:

- **Alpha Vantage or Twelve Data** for a usable free tier, with Twelve Data leaning toward higher request limits and broader exchange coverage
- **Polygon.io or Tiingo** for cleaner data or more demanding use, worth the setup cost
- **Finnhub** for its free-tier request limits alone
- **Nasdaq Data Link** for fundamentals or macroeconomic data rather than just prices

Free tiers and rate limits change often, so verify each provider's current pricing page before committing to one.



## Scraping Google Finance Data Directly

When the GOOGLEFINANCE function and the API alternatives above do not cover what you need, scraping the live Google Finance page is the way to go. Let's take a look at some scraping examples using Python's [requests](https://pypi.org/project/requests/) and [BeautifulSoup](https://pypi.org/project/beautifulsoup4/) libraries, which can be installed using `pip`:

bash```bash
$ pip install requests beautifulsoup4
```



### Scraping Ticker Data



Scraping ticker data allows you to gather essential stock information like stock price, company name and changes:

python```python
import requests
from bs4 import BeautifulSoup

# URL for Google Finance main page
url = "https://www.google.com/finance/?hl=en"

# Fetch the page content
response = requests.get(url, headers={"User-Agent": "Mozilla/5.0"})
soup = BeautifulSoup(response.text, "html.parser")

# Find the market overview cards (indices, forex, crypto, futures, commodities)
cards = soup.find_all("div", class_="ebt9Ze")

# Extract and print card details
for card in cards:

    def get_text(tag, class_name):
        element = card.find(tag, class_=class_name)
        return element.get_text(strip=True) if element else "N/A"

    # the card itself has no separate ticker text, it only lives in the
    # quote link, e.g. "./quote/YMW00:CBOT" -> "YMW00:CBOT"
    link = card.find("a", class_="HPIOqe")
    ticker = link["href"].removeprefix("./quote/") if link else "N/A"

    card_data = {
        "ticker": ticker,
        "company_name": get_text("bdi", "KzWCNc"),
        "price": get_text("span", "SpkPOc"),
        "price_change": get_text("span", "d6uVnc"),
    }
    print(card_data)

```



Example Output```
{'ticker': 'AMZN', 'company_name': 'Amazon.com Inc', 'price': '$214.10', 'price_change': '2.48%'}
{'ticker': 'BLS', 'company_name': 'BLS International Services Ltd', 'price': '₹389.15', 'price_change': '1.31%'}
{'ticker': 'IDHC', 'company_name': 'Integrated Diagnostics Holdings PLC', 'price': '$0.42', 'price_change': '1.06%'}
{'ticker': 'Index', 'company_name': 'Tadawul All-Share Index', 'price': '11,866.05', 'price_change': '0.54%'}
{'ticker': 'TSLA', 'company_name': 'Tesla Inc', 'price': '$330.24', 'price_change': '0.53%'}
{'ticker': 'AAPL', 'company_name': 'Apple Inc', 'price': '$225.12', 'price_change': '0.40%'}
```



This code extracts key stock data from Google Finance, including ticker, company name, current price, and daily change. These class names rotate periodically, so treat them as a snapshot rather than a permanent contract. If the scraper returns empty results, reinspect the page and update the selectors.

For more on parsing HTML like this, see our guide to

[Python lxml Tutorial: How to Parse HTML and XMLIn this tutorial, we'll take a deep dive into lxml, a powerful Python library that allows for parsing HTML and XML effectively. We'll start by explaining what lxml is, how to install it and using lxml for parsing HTML and XML files. Finally, we'll go over a practical web scraping with lxml.](https://scrapfly.io/blog/posts/intro-to-parsing-html-xml-python-lxml)

### Scraping Financial News



example news for NVDA stock on Google FinanceScraping financial news is valuable for understanding market trends, tracking company performance, and staying updated on industry developments.

Here's an example code guide:

python```python
import requests
from bs4 import BeautifulSoup

# Define the URL for Google Finance
url = "https://www.google.com/finance/?hl=en"

# Send a request to the Google Finance page
response = requests.get(url, headers={"User-Agent": "Mozilla/5.0"})
soup = BeautifulSoup(response.text, "html.parser")

# Locate the section containing news articles
news_section = soup.find_all("div", class_="LIT7If")

# Extract and print the titles of top news articles
for article in news_section[:5]:  # Limit to top 5 articles
    title_el = article.find("div", class_="TQWIEd")
    publisher_el = article.find("div", class_="WrUjhf")
    date_el = article.find("div", class_="JQ8Czd")
    link_tag = article.find("a", href=True)

    title = title_el.get_text(strip=True) if title_el else None
    publisher = publisher_el.get_text(strip=True) if publisher_el else None
    date = date_el.get_text(strip=True) if date_el else None
    link = link_tag["href"] if link_tag else None

    print({"Title": title, "Publisher": publisher, "Date": date, "Link": link})

```



Example Output{'Title': 'Fed holds interest rates steady, signals possible cuts later this year', 'Publisher': 'Reuters', 'Date': '3 hours ago', 'Link': 'https://www.reuters.com/markets/us/fed-holds-rates-steady'} {'Title': 'Nvidia shares rise after strong data center demand forecast', 'Publisher': 'CNBC', 'Date': '5 hours ago', 'Link': 'https://www.cnbc.com/2026/nvidia-data-center-demand-forecast'} {'Title': 'Oil prices climb as OPEC extends production cuts', 'Publisher': 'Bloomberg', 'Date': '1 day ago', 'Link': 'https://www.bloomberg.com/news/articles/oil-opec-production-cuts'} {'Title': 'Tesla deliveries beat estimates for the second straight quarter', 'Publisher': 'The Verge', 'Date': '1 day ago', 'Link': 'https://www.theverge.com/2026/tesla-deliveries-beat-estimates'} {'Title': 'Dollar steadies as traders await inflation data', 'Publisher': 'MarketWatch', 'Date': '2 days ago', 'Link': 'https://www.marketwatch.com/story/dollar-steadies-inflation-data'} ``` In this output, you can see the headline titles along with the publisher and date of publication. Scraping still earns its place because it is the only way to get data specific to the Google Finance page itself, like related tickers, region-specific watchlists, or the exact news items shown for a ticker. No named API replicates that view.



Scrapfly

#### Scale your web scraping effortlessly

Scrapfly handles proxies, browsers, and anti-bot bypass — so you can focus on data.

[Try Free →](https://scrapfly.io/register)## Scraping Google Finance Reliably With Scrapfly

Google Finance uses obfuscated CSS classes that rotate and sits behind anti-bot protection, so raw scrapers like the ones above tend to break over time or get blocked outright once you push past a handful of requests. A fetch layer that rotates proxies and handles anti-bot protection keeps extraction stable without hand-maintaining selectors every few weeks.



Scrapfly's [Web Scraping API](https://scrapfly.io/products/web-scraping-api) covers this:

- `asp=True` for anti-bot bypass, `render_js=True` for pages that need JavaScript rendering, and `country=` for geographic proxy targeting
- An AI Extraction API to pull ticker or news records directly, without hand-maintaining selectors
- First-class SDKs for [Python](https://scrapfly.io/docs/sdk/python), TypeScript, Go, and Rust, plus a Scrapy extension
- The [Unblocker](https://scrapfly.io/products/unblocker) product for simpler cases that just need a clean proxy



For example, we could replace our scraper code to use Scrapfly through the [python sdk](https://scrapfly.io/docs/sdk/python):

python```python
from scrapfly import ScrapflyClient, ScrapeConfig, ScrapeApiResponse
from bs4 import BeautifulSoup

scrapfly = ScrapflyClient(key="your scrapfly key")

response: ScrapeApiResponse = scrapfly.scrape(ScrapeConfig(
    url="https://www.google.com/finance/?hl=en",
    proxy_pool="public_residential_pool",
    country="us",
    asp=True,        # bypass anti-bot protection
    render_js=True,  # render JavaScript-loaded content
))

# response.content is the raw HTML content of the page
soup = BeautifulSoup(response.content, "html.parser")

# Find the market overview cards
cards = soup.find_all("div", class_="ebt9Ze")

# Extract and print card details
for card in cards:
    link = card.find("a", class_="HPIOqe")
    ticker = link["href"].removeprefix("./quote/") if link else "N/A"

    details_classes = {"name": ("bdi", "KzWCNc"), "price": ("span", "SpkPOc"), "price_change": ("span", "d6uVnc")}
    card_data = {"ticker": ticker}
    card_data.update({
        key: (
            element.get_text(strip=True) if (element := card.find(tag, class_=class_name)) else "N/A"
        )
        for key, (tag, class_name) in details_classes.items()
    })
    print(card_data)
```





## FAQ

How do I handle rate limiting when scraping Google Finance?[Implement request delays](https://scrapfly.io/blog/posts/how-to-rate-limit-asynchronous-python-requests) (1-2 seconds between requests), [use rotating residential proxies](https://scrapfly.io/blog/posts/how-to-rotate-proxies-in-web-scraping), respect robots.txt, and consider using ScrapFly's anti-bot bypass features. Monitor for [429 status codes](https://scrapfly.io/blog/posts/what-is-http-error-429-too-many-requests) and implement exponential backoff.







What's the difference between real-time and delayed stock data from Google Finance?Real-time data shows current market prices with minimal delay, while delayed data (typically 15-20 minutes behind) is free but less accurate for active trading. Google Finance provides both, with real-time data requiring more sophisticated scraping techniques.







Can I use Google Sheets GOOGLEFINANCE function instead of web scraping?Yes, Google Sheets GOOGLEFINANCE function can retrieve stock data programmatically, but it's slower, has rate limits, and requires Google authentication. Web scraping is more efficient for large-scale data collection.







How do I scrape historical stock prices from Google Finance?Use date range parameters in URLs (e.g., `?startdate=2023-01-01&enddate=2023-12-31`) or scrape the historical data section. [Parse JSON responses](https://scrapfly.io/blog/posts/how-to-use-python-to-parse-json) from [background API calls](https://scrapfly.io/blog/posts/how-to-scrape-hidden-apis) for more reliable historical data extraction.







Why does my Google Finance scraper break when the page layout changes?Google frequently updates their page structure and CSS classes. [Use more robust selectors](https://scrapfly.io/blog/posts/parsing-html-with-css), implement fallback parsing strategies, and regularly update your scraper. Consider using ScrapFly for automatic handling of layout changes.







Does Google provide an official for Google API Finance data?No, Google discontinued its API for Google Finance. Users can access data through Google Sheets or by scraping Google Finance web pages.







Are there alternatives to Google Finance for accessing stock data?Yes, Yahoo Finance is a popular alternative that provides comprehensive stock data, including real-time prices, historical data, and financial news.







Is scraping Google Finance data legal?Always consult the terms of service of the site you wish to scrape. Web scraping should respect legal guidelines and avoid excessive server requests.







Can I get real-time stock price alerts by scraping Google Finance?Yes, you can build a price monitoring system by scraping Google Finance at regular intervals and comparing the results. Combine this with [a price tracker](https://scrapfly.io/blog/posts/how-to-build-a-price-tracker-using-python-web-scraping) approach to get alerts when stocks hit target prices.









## Conclusion

The Google Finance API is gone for good, and no official replacement is coming. Light, occasional lookups are covered by the free GOOGLEFINANCE function in Sheets. Anything closer to production calls for a named API like Alpha Vantage, Twelve Data, or Polygon.io, with scraping the live page filling the gaps neither covers.

When that scraper breaks against rotating CSS classes and anti-bot checks, [Scrapfly's Web Scraping API](https://scrapfly.io/) keeps extraction running without the constant maintenance.



 

   [  Add as a preferred source ](https://google.com/preferences/source?q=scrapfly.io) Table of Contents















 

  Table of Contents- [Key Takeaways](#key-takeaways)
- [Is the Google Finance API Discontinued?](#is-the-google-finance-api-discontinued)
- [Using the GOOGLEFINANCE Function in Google Sheets](#using-the-googlefinance-function-in-google-sheets)
- [API Alternatives to Google Finance Data](#api-alternatives-to-google-finance-data)
- [Scraping Google Finance Data Directly](#scraping-google-finance-data-directly)
- [Scraping Ticker Data](#scraping-ticker-data)
- [Scraping Financial News](#scraping-financial-news)
- [Scraping Google Finance Reliably With Scrapfly](#scraping-google-finance-reliably-with-scrapfly)
- [FAQ](#faq)
- [Conclusion](#conclusion)
 
    Join the Newsletter  Get monthly web scraping insights 

 

  



Scale Your Web Scraping

Anti-bot bypass, browser rendering, and rotating proxies, all in one API. Start with 1,000 free credits.

  No credit card required  1,000 free API credits  Anti-bot bypass included 

 [Start Free](https://scrapfly.io/register) [View Docs](https://scrapfly.io/docs/onboarding) 

 Not ready? Get our newsletter instead. 

 

 ## Related Articles

 [     

 python api 

### Yahoo Finance API: How to Get Yahoo Finance Data in Python (2026)

Get Yahoo Finance data in Python with the yfinance library, the direct chart endpoint, and scraping, plus how to keep it...

 

 ](https://scrapfly.io/blog/posts/guide-to-yahoo-finance-api) [  

 python seo 

### How to Scrape Google Trends using Python

In this article we'll be taking a look at scraping Google Trends - what it is and how to scrape it? For this example, we...

 

 ](https://scrapfly.io/blog/posts/how-to-scrape-google-trends) [  

 python playwright 

### How to Scrape Google Maps

We'll take a look at to find businesses through Google Maps search system and how to scrape their details using either S...

 

 ](https://scrapfly.io/blog/posts/how-to-scrape-google-maps) 

  



   



 Scale your web scraping effortlessly, **1,000 free credits** [Start Free](https://scrapfly.io/register)