I have had no problem getting a CSV file with the 6000 or so NYSE stocks, but it just has the stock symbol and the market capitalization.
How can I get the NAICS (or SICS) code for the companies listed on the NYSE?
Quantitative Finance Stack Exchange is a question and answer site for finance professionals and academics. It only takes a minute to sign up.
Sign up to join this communityI have had no problem getting a CSV file with the 6000 or so NYSE stocks, but it just has the stock symbol and the market capitalization.
How can I get the NAICS (or SICS) code for the companies listed on the NYSE?
If you have the cik of the stock you can scrape them from the sec's website
This is a sample filing for apple cik : 320193
https://www.sec.gov/Archives/edgar/data/320193/000032019320000096/0000320193-20-000096.hdr.sgml
The tag you are looking for is ASSIGNED-SIC
The directories are open for search so just pick any filing at https://www.sec.gov/Archives/edgar/data/320193 or the cik of your choice
If you want sics for 6000 stocks you will have to make 6000*3 requests to the sec so you better wait between requests.
Once you have SICs you can easily map them to NAICS: https://www.naics.com/sic-naics-crosswalk-search-results/
In all likelihood by paying a vendor. SIC is a proprietary classification, it's owner isn't likely giving them away for free.
The search function on the SIC website does return SIC code for searched on securities though, so you may be able to write something to do a bulk search and store them yourself.
https://siccode.com/business/amazon-com-inc
Also, for ref, SIC isn't a common sector classification...GICS and ICB are more standard.