# Brazil CNPJ Lookup: Company Data, Partners & Contacts (`datadesk-io/brazil-cnpj-company-lookup`) Actor

Look up Brazilian companies by CNPJ: legal and trade name, status, CNAE activity, size, capital, address, phone, email and partners (QSA). Bulk list input, official Receita Federal data. $2 per 1,000.

- **URL**: https://apify.com/datadesk-io/brazil-cnpj-company-lookup.md
- **Developed by:** [DataDesk](https://apify.com/datadesk-io) (community)
- **Categories:** Lead generation
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.60 / 1,000 companies

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Brazil CNPJ Lookup: Company Data, Partners & Contacts

Enrich a list of **Brazilian CNPJ numbers** with **public Receita Federal company data** served by **BrasilAPI**. Each record has **legal name, trade name, registration status, opening date, company size, legal nature, share capital, main and secondary CNAE activities, full address, phone, email, Simples/MEI flags and the partner list (QSA)**. Paste a list, get a dataset. Check digits are validated before any request. No login, no key. **$2 per 1,000 companies.**

### Try it now (one click)

1. Click **Start**. The prefilled input looks up 3 well-known companies (Banco do Brasil, Petrobras, Itaú): in our latest check (Nov 16, 2026) it returned **3 companies in about 1 second**. An empty input runs a 5-company demo.
2. Paste your own CNPJs (one per line, with or without punctuation).
3. Download the results as CSV, Excel or JSON, or get them via API, webhooks, Make or Zapier.

**Price example:** 100 companies = **$0.205**, 1,000 companies = **$2.005** ($2.00 per 1,000 companies + $0.005 per run). Silver and Gold plan users pay 10% and 20% less per company. Apify's free plan includes $5 of usage every month, enough for about 2,495 companies. Invalid or not-found CNPJs and runs that find nothing are not charged.

#### Sample of real results

*Real rows from a local test run on Nov 16, 2026 (some columns). Each company also includes address, phone, CNAE codes, capital and the partner list.*

| CNPJ | Legal name | Status | City | Main activity | Partners |
|---|---|---|---|---|---|
| 00.000.000/0001-91 | BANCO DO BRASIL SA | ATIVA | BRASILIA, DF | Bancos múltiplos, com carteira comercial | 41 |
| 33.000.167/0001-01 | PETROLEO BRASILEIRO S A PETROBRAS | ATIVA | RIO DE JANEIRO, RJ | Extração de petróleo e gás natural | 8 |
| 60.701.190/0001-04 | ITAU UNIBANCO S.A. | ATIVA | SAO PAULO, SP | Bancos comerciais | 142 |

### What you get

| Field group | Fields |
|---|---|
| Identity | CNPJ (plain and formatted), legal name, trade name, headquarters flag |
| Status | registration status and date, opening date, Simples and MEI flags |
| Business | legal nature, size, share capital, main and secondary CNAE |
| Contact | address, city, state, postal code, phone, email |
| Partners | QSA partner names, roles, join dates and age range as published |

### Sources and coverage

| Source | Coverage | Data |
|---|---|---|
| BrasilAPI CNPJ (Receita Federal public data) | Brazil, all registered companies | Public company registry; no login or key |

### How to use it

1. Click **Try for free** (or **Start**): the prefilled input runs a quick test.
2. Adjust the filters (see examples below).
3. Click **Start** and wait a few seconds.
4. Open the **Output** tab and export as **JSON, CSV, Excel, XML or HTML**, or read the dataset via API.

### Input examples

**One company:**

```json
{"cnpjs": ["00.000.000/0001-91"]}
```

**Several companies:**

```json
{"cnpjs": ["00000000000191", "33000167000101", "60701190000104"], "maxCompanies": 100}
```

**Only active companies:**

```json
{"cnpjs": ["33.000.167/0001-01"], "onlyActive": true}
```

#### Input fields

| Field | Type | Description |
|---|---|---|
| `cnpjs` | array | Company tax numbers (CNPJ), with or without punctuation, e.g. 00.000.000/0001-91 or 00000000000191. One per line. Invalid check digits are skipped (not charged). Leave empty for a 5-company demo. |
| `onlyActive` | boolean | Save only companies with active registration status. |
| `maxCompanies` | integer | Maximum CNPJs looked up in this run (hard cap on cost). Default 20. |
| `onlyNewCompanies` | boolean | Return only companies not seen in previous runs with the same alerts key. Schedule daily for alerts. |
| `alertsKey` | string | Name for this alert memory (use a different key per saved search). |

### Output example

*Example values from a local test run.*

```json
{
  "cnpj": "00000000000191",
  "cnpjFormatted": "00.000.000/0001-91",
  "legalName": "BANCO DO BRASIL SA",
  "tradeName": "DIRECAO GERAL",
  "status": "ATIVA",
  "openedAt": "1966-08-01",
  "companySize": "DEMAIS",
  "mainActivityCode": 6422100,
  "mainActivity": "Bancos múltiplos, com carteira comercial",
  "email": null,
  "phone": "6134939002",
  "city": "BRASILIA",
  "state": "DF",
  "postalCode": "70040912",
  "partnersCount": 41,
  "url": "https://brasilapi.com.br/api/cnpj/v1/00000000000191",
  "statusDate": "2005-11-03",
  "isHeadquarters": true,
  "legalNature": "Sociedade de Economia Mista",
  "shareCapital": 120000000000,
  "secondaryActivities": [
    {
      "code": 6499999,
      "description": "Outras atividades de serviços financeiros não especificadas anteriormente"
    }
  ],
  "phone2": null,
  "address": "QUADRA SAUN QUADRA 5 BLOCO B TORRE I, II, III SN ANDAR T I SL S101 A S1602 T II SL C101 A C1602 TIII SL N101 A N1602",
  "neighborhood": "ASA NORTE",
  "simplesNacional": false,
  "mei": false,
  "partners": [
    {
      "name": "ALAN CARLOS GUEDES DE OLIVEIRA",
      "role": "Diretor",
      "joinedAt": "2023-05-17",
      "ageRange": "Entre 41 a 50 anos"
    },
    {
      "name": "ALBERTO MARTINHAGO VIEIRA",
      "role": "Diretor",
      "joinedAt": "2023-07-20",
      "ageRange": "Entre 41 a 50 anos"
    }
  ],
  "source": "brasilapi.com.br",
  "isNew": false,
  "scrapedAt": "2026-11-12T23:24:42.028270+00:00"
}
```

#### Output fields

| Field | Description |
|---|---|
| `cnpj / cnpjFormatted` | Tax number plain (14 digits) and formatted |
| `isHeadquarters` | True for the head office (matriz), false for a branch |
| `legalName / tradeName` | Razão social and nome fantasia |
| `status / statusDate / openedAt` | Registration status and dates |
| `companySize / legalNature / shareCapital` | Size, legal nature, capital |
| `mainActivity / secondaryActivities` | CNAE codes and descriptions |
| `email / phone / phone2` | Registered contact (email often empty for large companies) |
| `address / neighborhood / city / state / postalCode` | Registered address |
| `simplesNacional / mei` | Tax regime flags |
| `partners / partnersCount` | QSA partners as published |
| `url / source` | Source record |
| `isNew / scrapedAt` | Alerts flag and collection time (UTC) |

### Pricing

Pay-per-event: **$0.005** once per run that saves results + **$0.002 per company** ($2 / 1,000). Runs that save nothing are not charged.

| Companies saved | Approx. cost |
|---|---|
| 20 | $0.045 |
| 100 | $0.205 |
| 1,000 | $2.005 |
| 10,000 | $20.005 |

### Use cases

- Enrich a Brazilian lead list with status, CNAE, size and contacts
- KYC and supplier checks: status, capital and partners
- Sales targeting by CNAE activity, size and city
- Refresh a CRM company base on a schedule

### Integrations / API

Works with the Apify API, Schedules, webhooks, Make, Zapier, n8n and MCP. Example:

```bash
curl "https://api.apify.com/v2/acts/datadesk-io~brazil-cnpj-company-lookup/run-sync-get-dataset-items" \
  -H "Authorization: Bearer $APIFY_TOKEN" -H "Content-Type: application/json" \
  -d '{"cnpjs": ["00.000.000/0001-91"]}'
```

Python:

```python
from apify_client import ApifyClient
client = ApifyClient("<APIFY_TOKEN>")
run = client.actor("datadesk-io/brazil-cnpj-company-lookup").call(run_input={"cnpjs": ["00.000.000/0001-91"]})
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)
```

### MCP

Use this Actor from an MCP client (Cursor, Claude Desktop, etc.) through the Apify MCP server (`datadesk-io/brazil-cnpj-company-lookup`).

### Alerts mode

Turn on the **Only new** option and schedule the Actor daily: each run returns only companies not seen in earlier runs with the same alerts key (nothing is charged when there is nothing new).

### FAQ

**Do I need a key?** No. BrasilAPI is public and the Actor calls it directly.

**Can I search by name or CNAE?** No. This Actor looks up CNPJ numbers you provide. Pair it with a lead source that gives CNPJs.

**Are partner CPFs shown?** No. The public data masks CPFs; the Actor returns names, roles, join date and age range only.

### Limitations

- Lookup by CNPJ only; there is no name or CNAE search.
- Phones and emails are what the company registered and may be outdated or empty.
- Free public service: very large lists run slowly and some CNPJs can return temporary errors (logged and skipped).
- Companies not found are skipped and not charged.

### Start now

Click **Start** to run the prefilled example, then paste your CNPJ list. Missing a field or source? Open an issue on the **Issues** tab and tell us what you need.

### Support

Questions, bugs or a missing field? Email **datadesk.io@proton.me** or open an issue on the Actor page.

***

**ES:** Consulta empresas de Brasil por CNPJ: razón social, estado, CNAE, tamaño, capital, dirección, teléfono, email y socios. **$2 / 1.000.**
**PT:** Consulte empresas brasileiras por CNPJ: razão social, situação, CNAE, porte, capital, endereço, telefone, e-mail e sócios. **$2 / 1.000.**

# Actor input Schema

## `cnpjs` (type: `array`):

Company tax numbers (CNPJ), with or without punctuation, e.g. 00.000.000/0001-91 or 00000000000191. One per line. Invalid check digits are skipped (not charged). Leave empty to run a demo with 5 well-known companies.

## `onlyActive` (type: `boolean`):

Save only companies with active registration status.

## `maxCompanies` (type: `integer`):

Maximum CNPJs looked up in this run (hard cap on cost).

## `onlyNewCompanies` (type: `boolean`):

Return only companies not seen in previous runs with the same alerts key. Schedule daily for alerts.

## `alertsKey` (type: `string`):

Name for this alert memory (use a different key per saved search).

## Actor input object example

```json
{
  "cnpjs": [
    "00.000.000/0001-91",
    "33.000.167/0001-01"
  ],
  "onlyActive": false,
  "maxCompanies": 100,
  "onlyNewCompanies": false
}
```

# Actor output Schema

## `results` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "cnpjs": [
        "00.000.000/0001-91",
        "33.000.167/0001-01",
        "60.701.190/0001-04"
    ],
    "maxCompanies": 20
};

// Run the Actor and wait for it to finish
const run = await client.actor("datadesk-io/brazil-cnpj-company-lookup").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "cnpjs": [
        "00.000.000/0001-91",
        "33.000.167/0001-01",
        "60.701.190/0001-04",
    ],
    "maxCompanies": 20,
}

# Run the Actor and wait for it to finish
run = client.actor("datadesk-io/brazil-cnpj-company-lookup").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "cnpjs": [
    "00.000.000/0001-91",
    "33.000.167/0001-01",
    "60.701.190/0001-04"
  ],
  "maxCompanies": 20
}' |
apify call datadesk-io/brazil-cnpj-company-lookup --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,datadesk-io/brazil-cnpj-company-lookup"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/bJKje8bOrRlElgMM6/builds/ccYst6S6XPyINaHJ8/openapi.json
