CNPJ Scraper: Bulk Brazilian Company Lookup in 2026
The number every Brazilian company answers to
Every company and every branch in Brazil is registered with the Receita Federal, the federal tax authority, under a CNPJ number. The record behind it settles the basics of doing business there: the exact legal name (razão social), whether the company is active, what it does by CNAE code, whether it is taxed under Simples Nacional or registered as an MEI, and who its partners are.
Invoices, contracts and supplier onboarding all start from that number. Checking hundreds of them is where it gets slow.
What you can extract
One record per CNPJ:
- Identity: CNPJ, legal name, trade name (nome fantasia), legal nature, share capital, size, headquarters or branch
- Address: street, district, CEP, city, state and IBGE municipal code
- Contact: phone, fax and email
- Status: registration status (ATIVA, BAIXADA, SUSPENSA…), its date and reason, start of activity
- Activity: primary and secondary CNAE codes, with section, division, group and class
- Tax regime: Simples Nacional and MEI enrollment and exit dates
- Partners (QSA): name, role, entry date, age range and country
- State registrations: number, state and active flag
- Sources: which data sources fed the record
The technical challenge
- One number, two formats: CNPJs arrive as
00.000.000/0001-91or00000000000191, and spreadsheets drop leading zeros; normalize to 14 digits before matching. - Branches are separate records: the first eight digits identify the company and the next four the establishment, so each branch has its own CNPJ and record.
- Gaps between sources: no single source carries every field: state registrations, for instance, come from each state’s tax authority, not the Receita Federal.
DIY or a ready-made Actor?
The free route is real. The Receita Federal publishes the whole CNPJ register as open data: bulk files of companies, establishments, partners and Simples/MEI options that you download, load into a database and join to its code tables yourself. Its website looks up one CNPJ at a time, behind a CAPTCHA. Free APIs such as BrasilAPI, ReceitaWS and CNPJ.ws answer single lookups, each with its own limits and field coverage. For a one-off load of the whole country, the bulk files win; our API vs web scraping comparison covers the trade-offs.
Our CNPJ Lookup Scraper merges those three APIs into one record per company, with the CNAE hierarchy, state registrations and a field naming the sources used. Input is a list of CNPJs, raw or formatted, or a CNAE code filtered by state and city, up to 1,000 results per run. Invalid or unknown CNPJs come back with an error field and are not charged. Pay-per-result at about $0.0065 per company.
A practical workflow
- Clean the column: restore leading zeros so every CNPJ has 14 digits; formatting can stay.
- Enrich in batches: up to 1,000 per run, failed lookups flagged.
- Filter and segment: drop anything not ATIVA, then group by CNAE code, state, size and tax regime.
- Go wider: search a CNAE code in a target state and city for more companies in the same sector.
Use cases that pay off
- CRM enrichment: official names, status, CNAE codes and contacts on top of your lead list.
- Supplier validation: an active, correctly registered company before the first invoice.
- Prospect lists: companies by CNAE code, state and city.
- KYC and tax compliance: partners, legal nature and state registrations per counterparty.
The legal boundaries
- A public register: the Receita Federal publishes CNPJ registration data as open data.
- Partners are people: names and age ranges are personal data under Brazil’s LGPD; process them with a legal basis and keep only what you need.
- Contacts are not consent: a company email in the register is not permission to send marketing; check the LGPD before a campaign.
- Current state only: records show today’s registration, with no history of past statuses or partners.
Launch your scraping project
Need to automate data collection? Tell us what you need, we'll get back to you within 24 hours.
Send message