Need help with tiingo-python?
Click the “chat” button below for chat support from the developer who created it, or find similar developers for support.

About the developer

142 Stars 42 Forks MIT License 540 Commits 33 Opened issues


Python REST Client for interacting with the Tiingo Financial Data API

Services available


Need anything else?

Contributors list

# 2,554
166 commits
# 47,130
119 commits
# 345,171
19 commits
# 155,708
13 commits
# 105,006
2 commits

Tiingo Python

.. image:: :target:

.. image:: :target: :alt: Coverage

.. image:: :target: :alt: Documentation Status

.. image:: :target: :alt: Updates

.. image:: :target: :alt: Launch Binder

Tiingo is a financial data platform that makes high quality financial tools available to all. Tiingo has a REST and Real-Time Data API, which this library helps you to access. Presently, the API includes support for the following endpoints:

  • Stock Market Ticker Closing Prices + Metadata. Data includes full distribution details and is validated using a proprietary EOD Price Engine.
  • Curated news from top financial news sources + blogs. Stories are tagged with topic tags and relevant stock tickers by Tiingo's algorithms.


If you'd like to try this library before installing, click below to open a folder of online runnable examples.

.. image:: :target: :alt: Launch Binder

First, install the library from PyPi:

.. code-block:: shell

pip install tiingo

If you prefer to receive your results in

pandas DataFrame
format, and you do not already have pandas installed, install it as an optional dependency:

.. code-block:: shell

pip install tiingo[pandas]

Next, initialize your client. It is recommended to use an environment variable to initialize your client for convenience.

.. code-block:: python

from tiingo import TiingoClient # Set TIINGOAPIKEY in your environment variables in your .bashprofile, OR # pass a dictionary with 'apikey' as a key into the TiingoClient.

client = TiingoClient()

Alternately, you may use a dictionary to customize/authorize your client.

.. code-block:: python

config = {}

# To reuse the same HTTP Session across API calls (and have better performance), include a session key. config['session'] = True

# If you don't have your API key as an environment variable, # pass it in via a configuration dictionary. config['apikey'] = "MYSECRETAPIKEY"

# Initialize client = TiingoClient(config)

Now you can use

to make your API calls. (Other parameters are available for each endpoint beyond what is used in the below examples, inspect the docstring for each function for details.).

.. code-block:: python

# Get Ticker tickermetadata = client.getticker_metadata("GOOGL")

# Get latest prices, based on 3+ sources as JSON, sampled weekly tickerprice = client.getticker_price("GOOGL", frequency="weekly")

# Get historical GOOGL prices from August 2017 as JSON, sampled daily historicalprices = client.getticker_price("GOOGL", fmt='json', startDate='2017-08-01', endDate='2017-08-31', frequency='daily')

# Check what tickers are available, as well as metadata about each ticker # including supported currency, exchange, and available start/end dates. tickers = client.liststocktickers()

# Get news articles about given tickers or search terms from given domains articles = client.get_news(tickers=['GOOGL', 'AAPL'], tags=['Laptops'], sources=[''], startDate='2017-01-01', endDate='2017-08-31')

# Get definitions for fields available in the fundamentals-api, ticker is # optional definitions = getfundamentalsdefinitions('GOOGL')

# Get fundamentals which require daily-updated (like marketCap). A start- # and end-date can be passed. If omited, will get all available data. fundamentalsdaily = CLIENT.getfundamentals_daily('GOOGL', startDate='2020-01-01', endDate='2020-12-31')

# Get fundamentals based on quarterly statements. Accepts time-range like # daily-fundamentals. asReported can be set to get the data exactly like # it was reported to SEC. Set to False if you want to get data containing # corrections fundamentalsstmnts = CLIENT.getfundamentals_statements('GOOGL', startDate='2020-01-01', endDate='2020-12-31', asReported=True)

To receive results in

format, use the

.. code-block:: python

#Get a pd.DataFrame of the price history of a single symbol (default is daily): tickerhistory = client.getdataframe("GOOGL")

#The method returns all of the available information on a symbol, such as open, high, low, close, #adjusted close, etc. This page in the tiingo api documentation lists the available information on each #symbol:

#Frequencies and start and end dates can be specified similarly to the json method above.

#Get a pd.Series of only one column of the available response data by specifying one of the valid the #'metricname' parameters: tickerhistory = client.getdataframe("GOOGL", metricname='adjClose')

#Get a pd.DataFrame for a list of symbols for a specified metricname (default is adjClose if no #metricname is specified): tickerhistory = client.getdataframe(['GOOGL', 'AAPL'], frequency='weekly', metric_name='volume', startDate='2017-01-01', endDate='2018-05-31')

You can specify any of the end of day frequencies (daily, weekly, monthly, and annually) or any intraday frequency for both the

methods. Weekly frequencies resample to the end of day on Friday, monthly frequencies resample to the last day of the month, and annually frequencies resample to the end of day on 12-31 of each year. The intraday frequencies are specified using an integer followed by "Min" or "Hour", for example "30Min" or "1Hour".

Further Docs

  • Official Tiingo Documentation:
  • tiingo-python


  • Easy programmatic access to Tiingo API
  • Reuse requests session across API calls for better performance
  • On most methods, pass in
    as a keyword to have your responses come back as
    , which should have a lower memory impact than regular Python dictionaries.


  • Client-side validation of tickers
  • Data validation of returned responses
  • Case insensitivity for ticker names
  • More documentation / code examples

Feel free to file a PR that implements any of the above items.

Related Projects:

  • Riingo_ : Client for Tiingo in the R Programming Language

.. _Riingo:


  • Many thanks to Rishi Singh for creating Tiingo.

This package was created with Cookiecutter_ and the

_ project template.

.. _Cookiecutter: .. _


We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.