back to home

JerBouma / FinanceDatabase

This is a database of 300.000+ symbols containing Equities, ETFs, Funds, Indices, Currencies, Cryptocurrencies and Money Markets.

6,988 stars
720 forks
8 issues
PythonJupyter Notebook

AI Architecture Analysis

This repository is indexed by RepoMind. By analyzing JerBouma/FinanceDatabase in our AI interface, you can instantly generate complete architecture diagrams, visualize control flows, and perform automated security audits across the entire codebase.

Our Agentic Context Augmented Generation (Agentic CAG) engine loads full source files into context, avoiding the fragmentation of traditional RAG systems. Ask questions about the architecture, dependencies, or specific features to see it in action.

Embed this Badge

Showcase RepoMind's analysis directly in your repository's README.

[![Analyzed by RepoMind](https://img.shields.io/badge/Analyzed%20by-RepoMind-4F46E5?style=for-the-badge)](https://repomind-ai.vercel.app/repo/JerBouma/FinanceDatabase)
Preview:Analyzed by RepoMind

Repository Summary (README)

Preview
<img src="https://user-images.githubusercontent.com/46355364/220746807-669cdbc1-ac67-404c-b0bb-4a3d67d9931f.jpg" alt="Logo">

GitHub Sponsors Buy Me a Coffee LinkedIn Documentation Supported Python Versions PYPI Version PYPI Downloads

Call for Contributors to the FinanceDatabase
The FinanceDatabase serves the role of providing anyone with any type of financial product categorization entirely for free. To achieve this, the FinanceDatabase relies on community involvement to add, edit, and remove tickers over time. This is made easy enough that anyone, even those with a lack of coding experience, can contribute because of the use of CSV files that can be manually edited with ease.
I'd like to invite you to go to the Contributing Guidelines to understand how you can help. Thank you!

As a private investor, the sheer amount of information that can be found on the internet is rather daunting. Trying to understand what types of companies or ETFs are available is incredibly challenging, with millions of companies and derivatives available on the market. Sure, the most traded companies and ETFs can quickly be found simply because they are known to the public (for example, Microsoft, Tesla, S&P 500 ETF, or an All-World ETF). However, what else is out there is often unknown.

This database tries to solve that. It features 300,000+ symbols containing Equities, ETFs, Funds, Indices, Currencies, Cryptocurrencies, and Money Markets. It therefore allows you to obtain a broad overview of sectors, industries, types of investments, and much more.

The aim of this database is explicitly not to provide up-to-date fundamentals or stock data, as those can be obtained with ease (with the help of this database) by using the Finance Toolkit 🛠️. Instead, it gives insights into the products that exist in each country, industry, and sector and provides the most essential information about each product. With this information, you can analyze specific areas of the financial world and/or find a product that is hard to find. For examples of how you can combine this database with the earlier mentioned packages, see the Usage section.

Some key statistics of the database:

ProductQuantitySectorsIndustriesCountriesExchanges
Equities158.429126311183
ETFs36.7862952211153
Funds57.88115415211134
ProductQuantityCategory
Currencies2.556175 Currencies
Cryptocurrencies3.367352 Cryptocurrencies
Indices91.18364 Exchanges
Money Markets1.3673 Exchanges

The Finance Database is used within or referenced by:

<a href="https://algotrading101.com/learn/financedatabase-python-guide/"><img width="200" height="100" alt="AlgoTrading" src="https://github-production-user-asset-6210df.s3.amazonaws.com/46355364/265290727-4c113348-45fc-45fe-afb5-e043b738ee94.png"></a> <a href="https://twitter.com/pyquantnews/status/1576185955677077504?lang=en"><img width="200" height="100" alt="PyQuantNews" src="https://github-production-user-asset-6210df.s3.amazonaws.com/46355364/265290754-8c9025fb-3830-4f41-95fd-e5e6d0f84758.png"></a> <a href="https://alpha2phi.medium.com/investment-analysis-finance-database-61f47ecfe7ca"><img width="200" height="100" alt="Medium" src="https://github-production-user-asset-6210df.s3.amazonaws.com/46355364/265290765-dfbd0f4c-85eb-4de6-adba-345cb5189f31.png"></a>


Installation

Before installation, consider starring the project on GitHub, which helps others find the project as well.

<img width="1353" alt="image" src="https://github.com/JerBouma/FinanceDatabase/assets/46355364/4132edde-72f9-4e32-adfe-8872207f46ff">

To install the FinanceDatabase, simply use the following:

pip install financedatabase -U

Then within Python use:

import financedatabase as fd

Usage

This section explains in detail how the database can be queried with the related financedatabase package. Note that examples here are purposely cut off to a maximum of 10 entries due to the sheer size of the database. Furthermore, the summary column is also omitted for readability. For the full detailed results, see the Notebook here. Let's start by importing the package:

import financedatabase as fd

Initialization of each asset class is only required <u>once</u>. It is therefore important that you save the class to a variable so that you can query the database much more quickly. A simple example is shown below.

equities = fd.Equities()

equities.select()

A sample of the output is shown below:

symbolnamecurrencysectorindustry_groupindustryexchangemarketcountrystatecityzipcodewebsitemarket_capisincusipfigicomposite_figishareclass_figi
PMTA.DUPTC Inc.EURInformation TechnologySoftware & ServicesSoftwareDUSDusseldorf Stock ExchangeUnited StatesMABoston2210http://www.ptc.comLarge CapUS69370C100969370C100BBG000FC6SC5BBG000FC5PS5BBG001S6DNK6
VAW.FVAALCO Energy, Inc.EUREnergyEnergyOil, Gas & Consumable FuelsFRAFrankfurt Stock ExchangeUnited StatesTXHouston77042http://www.vaalco.comMicro CapUS91851C201791851C201BBG000CN15Y5BBG000CN15F6BBG001S76ZS7
ORC.DEOracle CorporationEURInformation TechnologySoftware & ServicesSoftwareGERXETRAUnited StatesTXAustin78741http://www.oracle.comMega CapUS68389X105468389X105BBG000C0RY38BBG000C0RWW0BBG001S5SJG6
PAYXPaychex, Inc.USDIndustrialsCommercial & Professional ServicesProfessional ServicesNMSNASDAQ Global SelectUnited StatesNYRochester14625-2396http://www.paychex.comLarge CapUS7043261079704326107BBG000BQT1J5BBG000BQSQ38BBG001S5V135
RI2A.FRigel Pharmaceuticals, Inc.EURHealth CarePharmaceuticals, Biotechnology & Life SciencesBiotechnologyFRAFrankfurt Stock ExchangeUnited StatesCASouth San Francisco94080http://www.rigel.comSmall CapUS7665596034766559603BBG000BKZNR4BBG000BKZNC0BBG001SD33Z0
PGENPrecigen, Inc.USDHealth CarePharmaceuticals, Biotechnology & Life SciencesBiotechnologyNMSNASDAQ Global SelectUnited StatesMDGermantown20876http://www.precigen.comSmall CapUS74017N105474017N105BBG004TDDJ32BBG000QL8VH9BBG001SSB3T5
GOGOGogo Inc.USDCommunication ServicesTelecommunication ServicesDiversified Telecommunication ServicesNMSNASDAQ Global SelectUnited StatesILChicago60606http://www.gogoair.comSmall CapUS38046C109938046C109BBG002CN8Y71BBG002CN8XN5BBG002CN8YD4
CRKComstock Resources, Inc.USDEnergyEnergyOil, Gas & Consumable FuelsNYQNew York Stock ExchangeUnited StatesTXFrisco75034http://www.comstockresources.comMid CapUS2057683029205768302BBG000DNBMJ3BBG000DNBK89BBG001S8FX55
OISOil States International, Inc.USDEnergyEnergyEnergy Equipment & ServicesNYQNew York Stock ExchangeUnited StatesTXHouston77002http://www.oilstatesintl.comSmall CapUS6780261052678026105BBG000BDDQ06BBG000BDDN94BBG001S7WK56
CVLC.BEVale S.A.EURMaterialsMaterialsMetals & MiningBERBerlin Stock ExchangeBrazilRJRio De Janeiro22250-145http://www.vale.comLarge CapUS91912E10559.19E+109BBG000HCJTN5BBG000HCJNQ5BBG001S7RS91

With show_options, all possible options are given per column. This is useful as it doesn't require loading the larger data files. For example, obtaining all options for equities is done as follows:

fd.show_options("equities")

This returns all available options for each column.

{'currency': array(['ARS', 'AUD', 'BRL', 'CAD', 'CHF', 'CLP', 'CNY', 'COP', 'CZK',
    'DKK', 'EUR', 'GBP', 'HKD', 'HUF', 'IDR', 'ILA', 'ILS', 'INR',
    'ISK', 'JPY', 'KES', 'KRW', 'LKR', 'MXN', 'MYR', 'NOK', 'NZD',
    'PEN', 'PHP', 'PLN', 'QAR', 'RUB', 'SAR', 'SEK', 'SGD', 'THB',
    'TRY', 'TWD', 'USD', 'ZAC', 'ZAR'], dtype=object),
 'sector': array(['Communication Services', 'Consumer Discretionary',
    'Consumer Staples', 'Energy', 'Financials', 'Health Care',
    'Industrials', 'Information Technology', 'Materials',
    'Real Estate', 'Utilities'], dtype=object),
 'industry_group': array(['Automobiles & Components', 'Banks', 'Capital Goods',
    'Commercial & Professional Services',
    'Consumer Durables & Apparel', 'Consumer Services',
    'Diversified Financials', 'Energy', 'Food & Staples Retailing',
    'Food, Beverage & Tobacco', 'Health Care Equipment & Services',
    'Household & Personal Products', 'Insurance', 'Materials',
    'Media & Entertainment',
    'Pharmaceuticals, Biotechnology & Life Sciences', 'Real Estate',
    'Retailing', 'Semiconductors & Semiconductor Equipment',
    'Software & Services', 'Technology Hardware & Equipment',
    'Telecommunication Services', 'Transportation', 'Utilities'],
       dtype=object)}

Since the equities database has already been loaded, it is also possible to use similar functionality from within the class as follows. The main difference is that this functionality allows you to see the options based on specific filtering. For example:

equities.show_options(country='Netherlands')

This shows a more concise list of parameters given the focus on the Netherlands.

{'currency': array(['ARS', 'AUD', 'BRL', 'CHF', 'CZK', 'EUR', 'GBP', 'ILA', 'MXN',
    'NOK', 'RUB', 'USD', 'ZAC'], dtype=object),
 'sector': array(['Communication Services', 'Consumer Discretionary',
    'Consumer Staples', 'Energy', 'Financials', 'Health Care',
    'Industrials', 'Information Technology', 'Materials',
    'Real Estate', 'Utilities'], dtype=object),
 'industry_group': array(['Automobiles & Components', 'Banks', 'Capital Goods',
    'Commercial & Professional Services',
    'Consumer Durables & Apparel', 'Consumer Services',
    'Diversified Financials', 'Energy', 'Food & Staples Retailing',
    'Food, Beverage & Tobacco', 'Health Care Equipment & Services',
    'Household & Personal Products', 'Insurance', 'Materials',
    'Media & Entertainment',
    'Pharmaceuticals, Biotechnology & Life Sciences', 'Real Estate',
    'Retailing', 'Semiconductors & Semiconductor Equipment',
    'Software & Services', 'Technology Hardware & Equipment',
    'Telecommunication Services', 'Transportation', 'Utilities'],
       dtype=object)}

Or only showing one specific parameter:

equities.show_options(
    selection='industry',
    sector='Financials',
    country='Netherlands')

Which returns:

array(['Banks', 'Capital Markets', 'Consumer Finance',
       'Diversified Financial Services', 'Insurance'], dtype=object)

Given this information, it then becomes possible to filter the database based on the parameters you are interested in. For example, if you are interested in 'Insurance' companies in the 'Netherlands', you can use the following. Note that I omit the sector here, given that the selection I make is on a deeper level and therefore it is a given that the sector is 'Financials'.

equities.select(
    country='Netherlands',
    industry='Insurance',
)

This returns a small selection of companies on all exchanges where the companies are listed.

symbolnamecurrencysectorindustry_groupindustryexchangemarketcountrystatecityzipcodewebsitemarket_capisincusipfigicomposite_figishareclass_figi
A16.FASR Nederland N.V.EURFinancialsInsuranceInsuranceFRAFrankfurt Stock ExchangeNetherlandsnanUtrecht3584 BAhttp://www.asrnl.comMid CapNL0011872643nanBBG00D2VFV96BBG00D2VFV78BBG00CWZ0HK0
A1EG34.SAAegon N.V.BRLFinancialsInsuranceInsuranceSAOBovespa SomaNetherlandsnanThe Hague2591 TVhttp://www.aegon.comMid CapNL0000303709nannannannan
AEGAegon N.V.USDFinancialsInsuranceInsuranceNYQNew York Stock ExchangeNetherlandsnanThe Hague2591 TVhttp://www.aegon.comLarge CapNL0000303709nanBBG000CKQTN4BBG000CKQSN6BBG001S6Y6M8
AEGOFAegon N.V.USDFinancialsInsuranceInsurancePNKOTC Bulletin BoardNetherlandsnanThe Hague2591 TVhttp://www.aegon.comMid CapNL0000303709nannannannan
AEND.DEAegon N.V.EURFinancialsInsuranceInsuranceGERXETRANetherlandsnanThe Hague2591 TVhttp://www.aegon.comMid CapNL0000303709nanBBG000DJK260BBG000DJHZF1BBG001S5V8R4

You'll see that the same company can appear multiple times. This is because by default all exchanges are shown. There are two methods to focus on one entry:

  • Use the only_primary_listing parameter. This will only show the primary listing of each company. This is useful mostly if you are looking at US exchanges.
  • Use the exchange or market parameter. This will allow you to filter on a specific exchange or market. This is useful when you are not necessarily looking at US exchanges and are already filtering on a specific country.

For example, when filtering on the Netherlands, it makes sense to select a Dutch exchange as well. This could be the exchange "AMS" or the market "Euronext Amsterdam". This will give you a much smaller selection.

equities.select(
    country='Netherlands',
    industry='Insurance',
    market='Euronext Amsterdam',
)

This gives the following three companies (not shortened):

symbolnamecurrencysectorindustry_groupindustryexchangemarketcountrystatecityzipcodewebsitemarket_capisincusipfigicomposite_figishareclass_figi
AGN.ASAegon N.V.EURFinancialsInsuranceInsuranceAMSEuronext AmsterdamNetherlandsnanThe Hague2591 TVhttp://www.aegon.comMid CapNL0000303709nanBBG000JN9DM6BBG000JN9C93BBG001S5V8R4
ASRNL.ASASR Nederland N.V.EURFinancialsInsuranceInsuranceAMSEuronext AmsterdamNetherlandsnanUtrecht3584 BAhttp://www.asrnl.comMid CapNL0011872643nanBBG00CWZ0HG5BBG00CWZ0HF6BBG00CWZ0HK0
NN.ASNN Group N.V.EURFinancialsInsuranceInsuranceAMSEuronext AmsterdamNetherlandsnanThe Hague2595 AShttp://www.nn-group.comLarge Capnannannannannan

Given that the Netherlands is a relatively small country, it is not uncommon for the list to become small quickly. For example, the same selection for the United States is already much larger, also utilizing the only_primary_listing parameter.

equities.select(
    country='United States',
    industry='Insurance',
    only_primary_listing=True
)

While not immediately obvious in this shortened output, it returns about 180 different companies.

symbolnamecurrencysectorindustry_groupindustryexchangemarketcountrystatecityzipcodewebsitemarket_capisincusipfigicomposite_figishareclass_figi
AFLAflac IncorporatedUSDFinancialsInsuranceInsuranceNYQNew York Stock ExchangeUnited StatesGAColumbus31999http://www.aflac.comLarge CapUS00105510281055102BBG000BBBRC7BBG000BBBNC6BBG001S5NGJ4
AJGArthur J. Gallagher & Co.USDFinancialsInsuranceInsuranceNYQNew York Stock ExchangeUnited StatesILRolling Meadows60008-4050http://www.ajg.comLarge CapUS3635761097363576109BBG000BBHZK4BBG000BBHXQ3BBG001S5NKC2
AMSFAMERISAFE, Inc.USDFinancialsInsuranceInsuranceNMSNASDAQ Global SelectUnited StatesLADeridder70634http://www.amerisafe.comSmall CapUS03071H100503071H100BBG000Q0JWB7BBG000Q0JJQ0BBG001SDH7B2
BROBrown & Brown, Inc.USDFinancialsInsuranceInsuranceNYQNew York Stock ExchangeUnited StatesFLDaytona Beach32114http://www.bbinsurance.comLarge CapUS1152361010115236101BBG000BWSJ77BBG000BWSGF4BBG001S5XFN0
CINFCincinnati Financial CorporationUSDFinancialsInsuranceInsuranceNMSNASDAQ Global SelectUnited StatesOHFairfield45014-5141http://www.cinfin.comLarge CapUS1720621010172062101BBG000BFPVV3BBG000BFPK65BBG001S5PTM0

For any of the variables, it is also possible to provide a list instead, which means that it will return all entries that match any of the variables. As an example, the queries above can be combined into one:

equities.select(
    country=['Netherlands', 'United States'],
    industry='Insurance',
    market=['Euronext Amsterdam', 'Nordic Growth Market', 'OTC Bulletin Board',
        'New York Stock Exchange', 'NASDAQ Global Select', 'NYSE MKT',
        'NASDAQ Capital Market']
)

This returns a larger selection of companies given the increased number of countries and markets.

symbolnamecurrencysectorindustry_groupindustryexchangemarketcountrystatecityzipcodewebsitemarket_capisincusipfigicomposite_figishareclass_figi
AAMEAtlantic American CorporationUSDFinancialsInsuranceInsuranceNGMNordic Growth MarketUnited StatesGAAtlanta30319-3054http://www.atlam.comNano Capnannannannannan
ACMTACMAT CorporationUSDFinancialsInsuranceInsurancePNKOTC Bulletin BoardUnited StatesCTFarmington6032http://www.acmatcorp.comNano Capnannannannannan
ACMTAACMAT CorporationUSDFinancialsInsuranceInsurancePNKOTC Bulletin BoardUnited StatesCTFarmington6032http://www.acmatcorp.comNano Capnannannannannan
AEGAegon N.V.USDFinancialsInsuranceInsuranceNYQNew York Stock ExchangeNetherlandsnanThe Hague2591 TVhttp://www.aegon.comLarge CapNL0000303709nanBBG000CKQTN4BBG000CKQSN6BBG001S6Y6M8
AEGOFAegon N.V.USDFinancialsInsuranceInsurancePNKOTC Bulletin BoardNetherlandsnanThe Hague2591 TVhttp://www.aegon.comMid CapNL0000303709nannannannan

If the current categorization doesn't lead to the results you are looking for, it is possible to use the search parameter. This allows you to filter on any column in the database via a custom string. This means that if the word or sentence you input is found somewhere in the column you select, it will return the result.

By default, the result will not be case sensitive, but you can adjust this by setting case_sensitive=True. You can also filter the index (symbol column) by using index as shown below. Just like the select function, you can also provide lists here.

equities.search(
    summary=["Robotics", "Education"],
    industry_group="Equipment",
    market='Frankfurt',
    index=".F"
)

This returns instruments that are listed on the Frankfurt Stock Exchange, are in an industry group with the word "Equipment," and have either "Robotics" or "Education" in the summary column. The index parameter is used to filter on the symbol column, which in this case is ".F". The filtering on the index is an alternative way of finding the exchange or market you are looking for.

symbolnamecurrencysectorindustry_groupindustryexchangemarketcountrystatecityzipcodewebsitemarket_capisincusipfigicomposite_figishareclass_figi
109.FCastlight Health, Inc.EURHealth CareHealth Care Equipment & ServicesHealth Care Providers & ServicesFRAFrankfurt Stock ExchangeUnited StatesCASan Francisco94105http://www.castlighthealth.comSmall Capnannannannannan
1KT.FKeysight Technologies, Inc.EURInformation TechnologyTechnology Hardware & EquipmentElectronic Equipment, Instruments & ComponentsFRAFrankfurt Stock ExchangeUnited StatesCASanta Rosa95403-1738http://www.keysight.comLarge CapUS49338L103549338L103BBG007DJZFD2BBG007DJZFC3BBG0059FN820
1N1.FNanalysis Scientific Corp.EURInformation TechnologyTechnology Hardware & EquipmentElectronic Equipment, Instruments & ComponentsFRAFrankfurt Stock ExchangeCanadaABCalgaryT2E 7C3http://www.nanalysis.comNano Capnannannannannan
1YO.FYangtze Optical Fibre And Cable Joint Stock Limited CompanyEURInformation TechnologyTechnology Hardware & EquipmentCommunications EquipmentFRAFrankfurt Stock ExchangeChinananWuhan430073http://www.yofc.comSmall Capnannannannannan
1ZU.FThe Pennant Group, Inc.EURHealth CareHealth Care Equipment & ServicesHealth Care Equipment & SuppliesFRAFrankfurt Stock ExchangeUnited StatesIDEagle83616http://pennantgroup.comSmall CapUS70805E10917.08E+113BBG00QJ35K78BBG00QJ35K69BBG00P33SZ15

Lastly, the Finance Database has a direct integration with the Finance Toolkit, making it possible to do financial analysis on the companies you've found in the Finance Database. Returning to the earlier example of the 3 insurance companies in the Netherlands, it becomes possible to load these into the Finance Toolkit with the to_toolkit functionality.

To be able to get started, you need to obtain an API Key from FinancialModelingPrep. This is used to gain access to 30+ years of financial statements, both annually and quarterly. Note that the Free plan is limited to 250 requests each day, 5 years of data, and only features companies listed on US exchanges.


<b><div align="center">Obtain an API Key from FinancialModelingPrep <a href="https://www.jeroenbouma.com/fmp" target="_blank">here</a>.</div></b>


Then you can go ahead and run the following code, changing the API_KEY to your own API Key:

API_KEY = "FINANCIAL_MODELING_PREP_API_KEY"

dutch_insurance_companies = equities.select(
    country='Netherlands',
    industry='Insurance',
    market='Euronext Amsterdam',
)

toolkit = dutch_insurance_companies.to_toolkit(
    api_key=API_KEY
)

With this integration, I can now access some of the most important financial metrics for these companies. Let's start simple with historical data:

toolkit.get_historical_data()

Which returns, selecting only "ASRNL.AS" as an example:

dateOpenHighLowCloseAdj CloseVolumeDividendsReturnVolatilityExcess ReturnExcess VolatilityCumulative Return
2025-03-3152.8652.9852.5652.9852.985476500-0.00490.0175-0.04740.02064.2726
2025-04-0153.2253.652.9853.4453.4448609800.00870.0175-0.03290.02064.3097
2025-04-0253.1853.5852.753.353.34857680-0.00260.0175-0.04460.02064.2984
2025-04-0352.3253.2252.1852.4252.425672420-0.01650.0175-0.0570.02064.2274
2025-04-045252.549.4550.450.44850240-0.03850.0175-0.07750.02064.0645

Now let's make it more advanced by automatically calculating 60+ financial ratios for each company. This is just a small snippet of what is available within the Finance Toolkit; see the GitHub page of the Finance Toolkit here or the example Notebook here for more information.

toolkit.ratios.collect_all_ratios()

Which returns, selecting only "ASRNL.AS" as an example with a few ratios:

2015201620172018201920202021202220232024
Interest Coverage Ratio4.05354.22876.61425.1523.22382.25083.11883.09624.11770
Income Before Tax Profit Margin0.10780.12650.18430.1590.15150.11040.12310.17830.10890.0701
Effective Tax Rate0.19230.23510.1950.23340.19830.20750.22330.21960.21810.2647
Return on Capital Employed0.01830.01920.02350.01760.02180.01450.02050.02050.02830.0382
Net Income per EBT0.79080.76030.79850.7430.79170.77980.7680.77050.7740.6972
EBT to EBIT Ratio0.74690.76110.84720.8010.76540.70230.76280.66540.32890.2389
EBIT to Revenue0.13270.1630.21070.18030.18850.14810.15530.25640.31960.2567
Debt-to-Assets Ratio0.04420.06050.05040.05460.0940.11720.09230.0680.08560.0771

All of these methods are also available for the other asset classes. The only difference is that the class name changes and the available columns. For example, for ETFs you would use fd.ETFs() instead of fd.Equities() and the select option has parameters such as category_group and family instead.

etfs = fd.ETFs()

etfs.select(
    category_group='Fixed Income'
)

This gives you results like the following:

symbolnamecurrencycategory_groupcategoryfamilyexchange
^BNDVANGUARD BD IDX FDUSDFixed IncomeInvestment Grade BondsVanguard Asset ManagementNIM
^BNDXVANGUARD CHARLOTTEUSDFixed IncomeInvestment Grade BondsVanguard Asset ManagementNIM
^VCITVANGUARD SCOTTSDALUSDFixed IncomeCorporate BondsVanguard Asset ManagementNIM
^VCLTVANGUARD SCOTTSDALUSDFixed IncomeCorporate BondsVanguard Asset ManagementNIM
^VCSHVANGUARD SCOTTSDALUSDFixed IncomeCorporate BondsVanguard Asset ManagementNIM

This also translates to the available options. For example, let's select fd.Indices() instead:

indices = fd.Indices()

indices.show_options()

A sample of the output is shown below:

{'category_group': array(['Alternatives', 'Cash', 'Commodities', 'Communication Services',
    'Consumer Discretionary', 'Consumer Staples', 'Currencies',
    'Derivatives', 'Energy', 'Equities', 'Financials', 'Fixed Income',
    'Health Care', 'Industrials', 'Information Technology',
    'Materials', 'Real Estate', 'Utilities'], dtype=object),
 'category': array(['Alternative', 'Blend', 'Bonds', 'Cash', 'Commercial Real Estate',
    'Commodities Broad Basket', 'Communications',
    'Consumer Discretionary', 'Consumer Staples', 'Corporate Bonds',
    'Currencies', 'Derivatives', 'Developed Markets',
    'Emerging Markets', 'Energy', 'Equities', 'Factors', 'Financials',
    'Frontier Markets', 'Government Bonds', 'Growth', 'Health Care',
    'High Yield Bonds', 'Industrials',
    'Inflation-Protected Securities', 'Investment Grade Bonds',
    'Large Cap', 'Materials', 'Micro Cap', 'Mid Cap',
    'Money Market Instruments', 'Municipal Bonds', 'REITs',
    'Real Estate Development', 'Real Estate Services',
    'Residential Real Estate', 'Small Cap', 'Technology', 'Trading',
    'Treasury Bonds', 'Utilities', 'Value'], dtype=object)}

Lastly, both the search and to_toolkit functions also apply to each of the asset classes, using fd.Funds() and fd.Cryptos() respectively. For example, let's find the funds that focus on pension plans:

funds = fd.Funds()

funds.search(summary='Pension')

A sample of the output is shown below:

symbolnamecurrencycategory_groupcategoryfamilyexchange
0P000017AH.FOpenBank Renta Variable Europa PPEUREquitiesEquitiesSantander Asset Management SGIICFRA
0P000017AJ.FAlcal Futuro Uno PPEURFinancialsAllocationCaser Pensiones EGFPFRA
0P0000189U.FCaser Julio 2021 PP AccEURFinancialsBondsCaser Pensiones EGFPFRA
0P000018ML.FCajamar Renta Variable PPEUREquitiesEquitiesCajamar Vida Se. y Re.FRA
0P000019H0.FBestinver Global PPEURFinancialsBlendBestinver PensionesFRA

For Cryptos, let's collect the historical data of Ethereum in multiple currencies:

cryptos = fd.Cryptos()

eth_cryptos = cryptos.select(
    cryptocurrency='ETH'
)

cryptos_toolkit = eth_cryptos.to_toolkit(
    api_key=API_KEY,
    start_date='2020-01-01'
)

cryptos_toolkit.get_historical_data(period='quarterly')

A sample of the output is shown below, focusing on ETH-BTC:

DateOpenHighLowCloseAdj CloseVolumeDividendsReturnVolatilityExcess ReturnExcess VolatilityCumulative Return
2024Q20.05590.05580.05540.05540.055410814500.09920.1590.05580.1442.6763
2024Q30.04060.04070.04030.04050.04051695790-0.2690.1433-0.3070.14451.9565
2024Q40.03580.03650.0360.03620.03622913170-0.10620.1857-0.15190.16791.7488
2025Q10.02210.02220.02170.02190.02191196650-0.3950.1813-0.43750.16391.058
2025Q20.02180.02170.02160.02160.02161952290-0.01370.1415-0.0530.13611.0435

Questions & Answers

In this section you can find answers to commonly asked questions. In case the answer to your question is not here, consider creating an Issue.

How is the data obtained?

The data is an aggregation of various publicly available sources. I strictly maintain the rule that all data in this database must be freely accessible to everyone. Data requiring API keys or paid subscriptions is never included. Information that companies charge for is typically owned and maintained by those companies, making public sharing of such data a violation of their Terms of Service (ToS). However, publicly available data can be freely shared (read more about the legality of web scraping here). This database will always remain <u>completely free</u>.

What categorization method is used?

The categorization for Equities is based on a loose approximation of GICS (Global Industry Classification Standard). This database attempts to reflect sectors and industries as accurately as possible through manual curation, without collecting any actual data from MSCI's proprietary sources. The official GICS datasets curated by MSCI remain the most up-to-date, paid solution and were not used in developing any part of this database. All other categorizations in the database are independently developed and can be freely modified.

How can I contribute?

Please see the Contributing Guidelines. Thank you!

How can I find out which countries, sectors and/or industries exist within the database without needing to check the database manually?

For this you can use the show_options function from the package attached to this database within a specific asset class or on a higher level without requiring any data to be loaded beforehand. See Usage for more information.

When I try collect data I notice that not all tickers return output, why is that?

Some tickers are merely holdings of companies and therefore do not really have any data attached to them. Therefore, it makes sense that not all tickers return data. If you are still in doubt, search the ticker on Google to see if there is really no data available. If you can't find anything about the ticker, consider updating the database by visiting the Contributing Guidelines.

How does the database handle changes to companies over time - like symbol/exchange migration, mergers, bankruptcies, or symbols getting reused?

For American exchanges, the database automatically updates every Sunday using data from this repository. This process includes checks for market cap changes and updates asset classifications accordingly. Delisted tickers are intentionally retained for historical research purposes.

While professional financial data services like Bloomberg charge over $25,000 annually for comprehensive market data maintenance, this database relies on community contributions. When companies outside American exchanges undergo changes (migrations, mergers, bankruptcies), we depend on community members to identify and update these entries.

Most companies don't change so rapidly that the database becomes obsolete - major changes like Facebook's rebrand to META are quickly incorporated. Even when companies go bankrupt, their ticker information remains valuable for historical analysis.

If you notice outdated information, please consider contributing through the Contributing Guidelines.

Contributions

This section is meant to thank those that contributed to the project. Looking to contribute as well? Have a look here.

UserContribution
desaijimmyMade changes to Equities dataset including the Split of Daimler to Mercedes-Benz and Daimler Trucks
nindogoIntroduced a variety of new equities from the Nairobi Securities Exchange and introduced the country Kenya into the dataset.
colin99dHelped in the conversion of the Finance Database package to Object-Orientated, making the code much more efficient.

Contact

If you have any questions about the FinanceDatabase or would like to share with me what you have been working on, feel free to reach out to me via:

f you'd like to support my efforts, either help me out via the Contributing Guidelines or Buy me a Coffee.

Star History Chart