Finding Company CIKs

The secedgar.cik_lookup.get_cik_map function is provided as a utility to easily fetch CIKs based on a company’s ticker or name.

secedgar.cik_lookup.get_cik_map()

Get dictionary of tickers and company names to CIK numbers.

Uses functools.lru_cache to cache response if used in later calls. To clear cache, use get_cik_map.cache_clear().

Note

All company names and tickers are normalized by converting to upper case.

Returns

Dictionary with keys “ticker” and “title”. To get dictionary

mapping tickers to CIKs, use “ticker”. To get company names mapped to CIKs, use “title”.

Note

If any tickers or titles are None, the ticker or title will be excluded from the returned dictionary.

New in version 0.1.6.

By default, get_cik_map fetches a dictionary using company tickers as keys.

Note

In both examples below, only the first 5 results are shown.

In [1]: from secedgar.cik_lookup import get_cik_map

In [2]: dict(list(get_cik_map()["ticker"].items())[:5])
Out[2]: 
{'AAPL': '320193',
 'MSFT': '789019',
 'BRK-B': '1067983',
 'UNH': '731766',
 'JNJ': '200406'}

To get a dictionary with the company names as the keys, use the “title” key.

In [3]: from secedgar.cik_lookup import get_cik_map

In [4]: dict(list(get_cik_map()["title"].items())[:5])
Out[4]: 
{'APPLE INC.': '320193',
 'MICROSOFT CORP': '789019',
 'BERKSHIRE HATHAWAY INC': '1067983',
 'UNITEDHEALTH GROUP INC': '731766',
 'JOHNSON & JOHNSON': '200406'}