Search API Connector Documentation
Import Yahoo Finance Data to Google Sheets
In this guide, we will walk through how to pull data from the Yahoo Finance API directly into Google Sheets, using the API Connector add-on for Sheets.
For this article, we'll use an unofficial Yahoo Finance API listed in the RapidAPI marketplace.
Contents
- Before You Begin
- Part 1: Subscribe to the Yahoo Finance API
- Part 2: Create your API Request
- Part 3: Pull Yahoo Finance API Data into Sheets
- Part 4: API Documentation
Before You Begin
Click here to install the API Connector add-on from the Google Marketplace.
Part 1: Subscribe to the Yahoo Finance API
- Create an account at RapidAPI and log in. While logged in, navigate to the YH Finance API located at https://rapidapi.com/apidojo/api/yh-finance
- Click Subscribe to Test
- You will now see a list of pricing plans, including a free plan if you're just getting started. Click Subscribe on plan for which you'd like to subscribe.
- Whichever plan you choose (even the free one), you'll need to enter your credit card details at this point, and can then return to the documentation.
Part 2: Create Your API Request
- Available endpoints are listed in the lefthand sidebar. Let's start with
GET
market/v2/get-quotes
- Scroll down and fill out any required parameters.
- If you like, click the Test Endpoint button to see the response in the RapidAPI window, and visually verify that your request has fetched the data you're looking for.
- Now click the Code Snippets tab, and choose
(Shell) cURL
from the dropdown. Click Copy Code to grab the entire curl snippet; we'll use that next.
Part 3: Pull Yahoo Finance API Data into Sheets
We can now enter this cURL snippet into API Connector using API Connector's cURL import tool.
- Open up Google Sheets and click Extensions > API Connector > Import/Export > Import cURL
- Paste in the cURL snippet we retrieved above. Click Import.
- You'll see the entire request pre-configured in the sidebar.
- Create a new tab and click Set current to use that tab as your data destination.
- Name your request and click Run. A moment later you’ll see the response from the Yahoo Finance API appear in your sheet.
- To get other financial data, play around with the endpoint list in the left pane in RapidAPI to retrieve other information. Each time you click an endpoint, the new URL will appear in the code snippet box, where you can copy and paste it into API Connector.
Part 4: API Documentation
Unofficial Yahoo API documentation: https://rapidapi.com/apidojo/api/yh-finance/