Python wrapper for the St. Louis Fed's FRED API.
Switch branches/tags
Nothing to show
Pull request Compare This branch is 6 commits ahead, 40 commits behind zachwill:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.


Python wrapper of the St. Louis Federal Reserve Bank's FRED API web service for retrieving economic data.

FRED API Documentation:

Sign up for a FRED API key:


Without your API key saved in the file:

>>> from fred import Fred
>>> Fred('my_api_key').category(category_id=125)

With your API key saved in the fred_api_key file:

>>> from fred import Fred
>>> Fred().category(category_id=125)


  • category -- Get economic data for a specific category.

    >>> Fred().category(category_id=120)
  • releases -- Get all releases of economic data.

    >>> Fred().releases(limit=10)

    >>> Fred().releases('dates', xml_output=True)
  • release -- Get economic data for a specific release.

    >>> Fred().release('series', release_id=51)
  • series -- Get economic series of data.

    >>> Fred().series('search', search_text="money stock")

    >>> Fred().series(series_id='IRA')
  • sources -- Get all of FRED's sources of economic data.

    >>> Fred().sources()
  • source -- Get a single source of economic data.

    >>> Fred().source(source_id=51)
  • api -- Generic way of interacting with the FRED API.

    >>> Fred().api('release', 'dates', release_id=51)

    >>> Fred().api('category', category_id=119)

NOTE: Normally, data is returned in dictionary format instead of XML. If you're looking for XML output, however, just pass in the xml_output=True argument to a method.

>>> Fred().releases(xml_output=True)


Author: Zach Williams

All code released under the Unlicense (a.k.a. Public Domain).