> ## Documentation Index
> Fetch the complete documentation index at: https://docs.companyenrich.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Similar Companies API filters

> How to narrow a lookalike company search with filters: limit lookalikes to a market, exclude seeds and existing customers, choose between a minimum score and a filter, and see which filters you can add.

A [lookalike search](https://docs.companyenrich.com/docs/similar-companies-api.md) takes the same `filter` object as any other company search. The seed domains decide what the results look like, and filters decide which companies are allowed in. The same `filter` works in count, preview, and export requests.

This page covers what is specific to lookalike search. For the matching rules, accepted values, and CLI flag of each filter, see the full [Company Search API filters](https://docs.companyenrich.com/docs/company-search-api-filters.md) reference.

## Filters and lookalike options

Two kinds of setting shape a lookalike search. Use the one that matches what you want to change.

| You want to | Use |
| - | - |
| Keep only lookalikes in a market, size, or stage | `filter` |
| Leave out companies you already know | `filter.domain` with `notIn` |
| Drop lookalikes that are only weakly similar | `lookalike.minScore` |
| Change how much similarity counts in the ranking | `lookalike.weight` |

A lookalike search cannot be combined with a semantic search, so describe your market with filters, not with a description.

## Limit lookalikes to your market

Seeds find similar companies anywhere. Add filters to keep the ones you can sell to.

```json theme={null}
{
  "lookalike": { "domains": ["stripe.com", "adyen.com"] },
  "filter": {
    "country": ["US", "CA"],
    "employees": ["51-200", "201-500"],
    "type": "private"
  }
}
```

## Exclude seeds and existing customers

Put the domains you do not want back in `filter.domain` with `notIn`. Add your seeds and current customers there if you want to be sure they are left out.

```json theme={null}
{
  "lookalike": { "domains": ["stripe.com", "adyen.com"] },
  "filter": {
    "domain": { "notIn": ["stripe.com", "adyen.com", "checkout.com", "mollie.com"] }
  }
}
```

## Require companies you can act on

The `require` filter keeps only companies that have the fields you need, such as a LinkedIn page or a revenue range.

```json theme={null}
{
  "lookalike": { "domains": ["notion.so"] },
  "filter": { "require": ["linkedin", "revenue"] }
}
```

## Minimum score or filter

`lookalike.minScore` and `filter` remove different companies:

* `minScore`, from 0 to 1, drops companies that are not similar enough to the seeds.
* `filter` drops companies that do not meet an exact criterion, however similar they are.

Use both to get close matches inside your market.

```json theme={null}
{
  "lookalike": { "domains": ["notion.so"], "minScore": 0.7 },
  "filter": { "country": "US", "employees": ["11-50", "51-200"] }
}
```

Filtered results still come back in ranked order. Keep that order, and do not sort by score.

## Filters you can add

Every company search filter works with a lookalike search.

| Purpose | Filters |
| - | - |
| Market | `country`, `region`, `state`, `city` |
| Size | `employees`, `reportedEmployees`, `revenue`, `workforceSize` |
| Kind of company | `type`, `categories`, `naicsCodes`, `keywords`, `technologies` |
| Age and stage | `foundedYear`, `fundingRounds`, `fundingAmount`, `fundingYear`, `workforceGrowth` |
| Specific companies | `domain`, `id`, `query` |
| Data you need | `require` |

See [Company Search API filters](https://docs.companyenrich.com/docs/company-search-api-filters.md) for what each one accepts.

## People at lookalike companies

On a [people search](https://docs.companyenrich.com/docs/people-search-api.md), the same two fields go inside `company`: `company.lookalike` for the seeds and `company.filter` for the company filters.

```json theme={null}
{
  "filter": { "seniority": ["c-suite", "vp"] },
  "company": {
    "lookalike": { "domains": ["stripe.com", "adyen.com"] },
    "filter": { "country": "US" }
  }
}
```

## In the CLI

Add filter flags to `company similar`. Use `--exclude-domain` to leave companies out and `--min-score` to drop weak matches:

```bash theme={null}
companyenrich company similar stripe.com adyen.com --country US,CA --employees 51-200,201-500
companyenrich company similar notion.so --min-score 0.7 --exclude-domain notion.so,coda.io
```

## Related pages

> [card] [Company Search API filters](https://docs.companyenrich.com/docs/company-search-api-filters.md)
>
> The full reference: every filter, matching rule, and accepted value.

> [card] [Similar Companies API](https://docs.companyenrich.com/docs/similar-companies-api.md)
>
> Ranking, scores, pricing, limits, and V1 mapping.

> [card] [Similar Companies API examples](https://docs.companyenrich.com/docs/similar-companies-api-examples.md)
>
> Ready-to-run lookalike searches.

> [card] [Field values](https://docs.companyenrich.com/docs/field-values.md)
>
> Every accepted value for ranges, types, and categories.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.