Merge & Dedupe Datasets – Company & Lead Deduplication
Pricing
from $0.20 / 1,000 rows
Merge & Dedupe Datasets – Company & Lead Deduplication
Datasets, files or inline JSON in, one merged dataset without duplicates out – streaming, on small memory, with limited permissions. Company mode to deduplicate leads: lead lists in, one row per company out, matched by company name, website domain, email domain or phone, with the reason in each row.
Pricing
from $0.20 / 1,000 rows
Rating
0.0
(0)
Developer
Perceptron Data
Maintained by CommunityActor stats
0
Bookmarked
2
Total users
1
Monthly active users
23 minutes ago
Last modified
Categories
Features
Share
Dataset Merge & Company Dedupe
Datasets, files or rows in, one merged dataset without duplicates out – and for lead lists one row per company, with the reason for every merge. Rows that share a website domain, an email domain, a phone number or the same company name without its legal form at the same place become one row; matchedBy says why.
Limits: nothing is fetched from the web – a run reads the datasets, records and files you give it, nothing else. Companies are matched by fixed rules on what is in your rows: two differently abbreviated names are not guessed to be the same company, and two different websites stay two companies even when they share a phone number. Branches of one company become one row in company mode. A file may have up to 400 MB; a company list of several hundred thousand rows needs more memory, and the run says so before it starts instead of stopping halfway.
| Source | Company | Website | Phone | Place |
|---|---|---|---|---|
| map listing | Muster Autohaus GmbH & Co. KG – Filiale Nord | https://www.example.com/kontakt?utm_source=maps | 030 1234567 | 10115 Berlin |
| contact export | Muster Autohaus GmbH & Co. KG | example.com | +49 30 123 45 67 | 10115 Berlin |
| job board | MUSTER AUTOHAUS GmbH & Co. KG Niederlassung Berlin | – | – | 10117 Berlin |
→ one row with mergedRows: 3 and matchedBy: ["domain", "phone", "company_name_place"]. A made-up company in the shape of real rows.
Three modes:
dedupe(default) – remove rows that agree in the fields you name, or in every field. Case, blanks,https://www., tracking parameters and the way a phone number is written do not make two rows different.merge– put several sources into one dataset, in the order you give them.companies– one row per company. Every merged row carriesmergedRows,matchedBy, the shared values inmatchEvidenceand thesourcesit was made from; empty fields are filled from the other rows.
Runs with limited permissions: datasets and key-value stores are passed in fields that give the run read access to exactly these storages. No login, no API key, no proxy.
How to use – step by step
- Click Try for free on this page (a free Apify account is enough). The input form opens empty; a run without any input processes ten example rows so you can see the output.
- Pick your datasets under Datasets – the order is their rank – or paste addresses of CSV, JSON or JSON Lines files under File addresses, or rows under Rows in the input.
- Choose What to do: remove duplicates, merge only, or one row per company.
- For duplicates, name the fields that make two rows the same (for example
urloremail); leave them empty to compare whole rows. - Click Start. The result is in the Output tab; the record
SUMMARYin the key-value store says how many rows were read per source, written and found to be duplicates, and – in company mode – why rows were merged and which links were not drawn. - To check the decisions first, set What to write to
all: every row comes back with its group number.
Use cases
- Lead lists from several sources – map listings, a directory export, job ads and your CRM export describe the same companies in four spellings; get one row per company with the best-filled fields.
- Before an outreach or enrichment run – pay for every company once, not for every spelling of it.
- Scheduled scrapes – merge the datasets of several runs and keep each URL, product or job once.
- Cleaning one dataset – remove exact duplicates that differ in case, blanks or tracking parameters.
- AI agents and workflows – one tool call turns several result sets into one list; the status message and
SUMMARYsay exactly what happened.
Input examples
Remove duplicates from two datasets by URL, keep the row from the top-ranked dataset:
{ "datasets": ["aBcDeFgHiJkLmNoPq", "rStUvWxYz01234567"], "dedupeFields": ["url"] }
One row per company from a map scrape, a contact export and rows of your own:
{"datasets": ["aBcDeFgHiJkLmNoPq"],"fileUrls": ["https://files.example.org/contacts.csv"],"items": [{ "company": "Muster Autohaus GmbH & Co. KG", "website": "example.com", "owner": "Anna" }],"mode": "companies","defaultCountry": "DE"}
Look at every decision before you rely on it:
{ "datasets": ["aBcDeFgHiJkLmNoPq"], "mode": "companies", "output": "all", "maxRows": 2000 }
Keep only German rows with a website, write three columns, and also append the result to a dataset of yours:
{"datasets": ["aBcDeFgHiJkLmNoPq"],"dedupeFields": ["website"],"filters": [{ "field": "countryCode", "op": "eq", "value": "DE" }, { "field": "website", "op": "exists" }],"keepFields": ["title", "website", "phone"],"renameFields": { "title": "companyName" },"outputDataset": "collected-leads"}
Input fields
| Field | Meaning |
|---|---|
datasets | Apify datasets (IDs), in rank order. The run gets read access to exactly these. datasetIds is read as the same field. |
fileUrls | Public addresses of CSV (with header row), JSON (a list of objects) or JSON Lines files; .gz is unpacked. |
keyValueStore, recordKeys | A key-value store and the keys of records that hold rows, e.g. the OUTPUT of another run. |
items | Rows given directly as a JSON list. |
mode | dedupe (default), merge or companies. |
dedupeFields | Fields that make two rows the same; empty = the whole row. Nested fields as address.city. fields is read as the same field. |
normalize | On by default: ignore case, runs of blanks, https://www., a trailing slash, tracking parameters and the spelling of phone numbers. |
keep | first (default in dedupe), last, mostComplete, or merge (default in companies): which row stays. |
output | unique (default), duplicates (the removed rows) or all (every row with its matchGroup). |
matchOn | Company mode: which marks may link rows – domain, email_domain, phone, company_name. Default: all. |
nameMatch | with_place (default): the name counts together with the same postal code or town. anywhere: the name alone counts. |
companyNameField, websiteField, emailField, phoneField, cityField, postalCodeField | Name a field to use it; empty = found by its usual names, in every source separately. |
defaultCountry | Country of phone numbers written without a country code, when the row names none. |
keepFields, dropFields, renameFields | Columns to keep, to drop, to rename – applied after duplicates are found. |
filters, filterMode | Keep rows that match conditions (eq, ne, contains, notContains, exists, missing, gt, gte, lt, lte); all or any. |
addSourceField | Add sources (source and row number) to every row. |
outputDataset | A dataset of yours that also receives the rows; the run gets read and write access to exactly this one. outputDatasetId is read as the same field. |
maxRows | Read at most this many rows over all sources – for a small trial. |
Output example
A merged row in company mode (keep: merge): the row of the top-ranked source, its empty fields filled from the others, and four fields that explain the merge.
{"title": "Muster Autohaus GmbH & Co. KG – Filiale Nord","website": "https://www.example.com/kontakt?utm_source=maps","phone": "030 1234567","postalCode": "10115","city": "Berlin","countryCode": "DE","companyName": "Muster Autohaus GmbH & Co. KG","email": "info@example.com","company": "MUSTER AUTOHAUS GmbH & Co. KG Niederlassung Berlin","mergedRows": 3,"matchedBy": ["domain", "email_domain", "phone", "company_name_place"],"matchEvidence": {"domain": "example.com","email_domain": "example.com","phone": "+49301234567","companyNameKey": "musterautohaus","postalCode": "10115"},"sources": [{ "source": "dataset:aBcDeFgHiJkLmNoPq", "row": 17 },{ "source": "file:1:files.example.org/contacts.csv", "row": 3 },{ "source": "items", "row": 1 }]}
Rows that were not merged come out as they went in. With output: duplicates or all, every row carries matchGroup; in company mode all also adds companyNameKey, the name as it was compared.
The Output tab shows the rows in three views: Rows with every field, Lead columns with company, website, email, phone, postalCode and city next to the fields that explain a merge (rows that name these fields differently show empty cells there), and Merged companies with the reasons only.
The record SUMMARY of a run holds: its status (done, or rejected with the reason in error – see "What does a run cost?"), rows read per source, rows written, rows charged, duplicates found, merged companies per reason, the fields used for name, website, email, phone and place, rows without any usable mark, and every link that was not drawn, with its reason and examples.
When two rows are the same company
matchedBy | Rule | Never linked when |
|---|---|---|
exact_key | the fields in dedupeFields agree | – |
domain | same registrable domain of the website (shop.example.co.uk = example.co.uk) | the address is shared by many companies: social profiles, map links, marketplaces, directories, link lists, short links |
email_domain | same domain of the email address, or the email domain of one row is the website of another | the mailbox is a public provider (gmail.com, gmx.de, t-online.de …) |
phone | same number after normalising, at least 7 digits | the country is unknown for a number without country code |
company_name_place | same name without legal form, and the same postal code or town | the names carry different legal forms (Müller GmbH, Müller AG); a name without legal form has different postal codes in one town |
company_name | same name without legal form – with nameMatch: anywhere | as above; the name is one everyday word (Hotel, Consulting) |
Locks that hold for every rule: two different websites are never put into one company; a domain, email domain or phone number that more than five differently named companies share (a switchboard, a portal) links nobody. Every link not drawn is counted in SUMMARY. Links carry over: A and B share a domain, B and C a phone number – one company.
The name without legal form: FERCHAU GmbH Niederlassung Augsburg and Ferchau GmbH are the same name; so are Acme Inc., ACME LLC and Acme S.r.l.. The table of legal forms holds 63 forms in 102 spellings – from Germany, the rest of Europe, the US and Asia-Pacific. Short forms that are also words (AS, AB, SA, Co) count only at the end of a name, so AS Roma and SAS Institute keep their names.
Limits – measured, not assumed
- Checked by hand: on a list of 1,095 real rows from three kinds of sources – 289 map listings, 150 rows with the legal notice data of their websites, 656 job ads – company mode formed 223 merged groups. All 223 were read one by one: 208 are the same company, 15 are two companies of one corporate group that share a website (for example a holding and its operating company), none put unrelated companies together (22 November 2026).
- Missed on that list: names that one source abbreviates (
Mgmt.forManagement, a leading abbreviation), and one operator with twelve listings under twelve different domains. Rather a duplicate missed than two companies merged. - One company per website: a parent and its subsidiary with the same website become one row. Use
matchOnwithoutdomainif you need them apart. - Job-board rows carry the postal code of the workplace. A name with its legal form still counts as one company per town; a name without legal form does not.
- Names in other scripts (Cyrillic, Chinese, Japanese) are compared as written; their legal forms are not removed.
- Two passes:
companies, anddedupewithkeepother thanfirst, read every source twice. A source that changes while the run reads it ends the run with a clear message. - Speed and memory: Apify platform runs of 22 November 2026 with the default 512 MB and rows of about 1 kB – 15,000 rows deduplicated by two fields in 8 seconds (peak memory 112 MB), the same with
keep: mergein 16 seconds, 4,500 rows in company mode in 7 seconds (88 MB). Larger inputs were measured outside the platform, on one computer under a 512 MB memory limit: one million rows indedupe(peak 89 MB without Apify's own share), 100,000 rows incompanies(180 MB). One million rows in company mode do not fit into 1 GB; the run then asks for more memory before it starts.
Permissions and your data
The run reads the storages you pass in datasets, keyValueStore and outputDataset and the files behind fileUrls – nothing else in your account, and nothing on the web. An ID written anywhere else in the input is plain text and grants no access. File addresses must be public web addresses; addresses inside private networks are refused. Your rows are processed inside the run and written to the run's dataset; they are not sent anywhere else.
What does a run cost?
$0.00005 per run start, then per input row processed – cheaper on bigger Apify plans:
| Your Apify plan | Per row in merge and dedupe (row) | Per row in companies (company-row) |
|---|---|---|
| Free | $0.0003 | $0.001 |
| Starter | $0.00027 | $0.0009 |
| Scale | $0.00024 | $0.0008 |
| Business & Enterprise | $0.0002 | $0.0007 |
| Example (Free plan, incl. $0.00005 run start) | Cost |
|---|---|
| 10,000 rows, duplicates removed | $3.00 |
| 10,000 rows, one row per company | $10.00 |
| The ten example rows of an empty input | $0.003 |
Prices are Apify free plan prices as of 22 November 2026. Counted is every input row the run processed, also rows the filters left out – reading them is the work. A run that cannot start its work is rejected: when a source cannot be read, when the input cannot be used, or when your maximum cost per run, the timeout or the memory would not be enough for the whole input. A rejected run reads, writes and charges no row – it costs the $0.00005 run start. It ends successfully with an empty dataset, its status message begins with Rejected: No rows were processed — and names what to change (the value that is needed, the source that cannot be read), and SUMMARY holds "status": "rejected" and the reason in error. So a schedule or an agent that reads only the run's status should also read SUMMARY.status. A run fails only when it stops after its work began; its message then says that the result is incomplete.
A maximum cost that misses the whole input by a few rows does not reject the run. A limit typed as rows × price is short of exactly one row, because the run start comes out of it first: up to one row, or 0.5% of the rows, the run does all its work, charges up to your limit and says how many rows it did without a charge (rowsNotCharged in SUMMARY). A run that Apify moves to another server, or that you resurrect, continues where it stopped: no row is written or charged twice.
Coming from another merge tool?
Inputs written for other merge-and-dedup tools keep working where the meaning is the same: datasetIds → datasets, fields → dedupeFields, output: unique-items / duplicate-items → unique / duplicates, mode: dedup-after-load → dedupe (or merge when no fields are given), outputDatasetId → outputDataset, fieldsToLoad → keepFields, limit → maxRows, appendDatasetIds → addSourceField. The status message says what was read as what.
Rejected with a clear message, before any row is read: code in the input (preDedupTransformFunction, postDedupTransformFunction – use filters, keepFields, dropFields, renameFields), loading all runs of an Actor or task (actorOrTaskId – a run with limited permissions cannot list your runs; pass the dataset IDs), datasetIdsOfFilterItems, offset, output: nothing.
Changelog
- 23 November 2026 – A run that cannot start its work is now rejected instead of failed: it ends successfully with no rows, the status message begins with
Rejected: No rows were processed —, andSUMMARYholds"status": "rejected"and the reason inerror. A maximum cost that misses the input by one row (the run start comes out of the limit first) or by up to 0.5% of the rows no longer rejects the run: it does all rows and charges up to the limit.SUMMARYof every run now hasstatus. - 22 November 2026 – Company names:
Stiftungcounts as part of the name. Two foundations whose names begin alike (Evangelische Stiftung Nord,Evangelische Stiftung Süd) stay two companies, and a foundation is no longer put together with a namesake that carries no legal form. A word such asRegionorStandortstays when it is the first word of a name (Region Hannover). - 22 November 2026 – New view Lead columns in the Output tab: the usual columns of a lead list next to the fields that explain a merge.
- 22 November 2026 – First version: merge datasets, records, files and rows; remove duplicates by fields or whole rows; company mode with reasons and shared values in every merged row; limited permissions; restart without double rows or double charges.
Auf Deutsch: Datasets zusammenführen und Dubletten entfernen – eine Zeile je Firma
Datasets, Dateien oder Zeilen rein, ein zusammengeführtes Dataset ohne Dubletten raus – und bei Lead-Listen eine Zeile je Firma, mit dem Grund für jede Zusammenlegung. Zeilen mit derselben Website-Domain, derselben E-Mail-Domain, derselben Telefonnummer oder demselben Firmennamen ohne Rechtsform am selben Ort werden eine Zeile; matchedBy nennt den Grund. Es wird nichts aus dem Netz geholt: Der Lauf liest die Datasets, Records und Dateien, die Sie angeben.
dedupe(Vorgabe): Zeilen entfernen, die in den genannten Feldern oder in allen Feldern übereinstimmen. Groß- und Kleinschreibung, Leerzeichen,https://www., Tracking-Parameter und die Schreibweise von Telefonnummern machen keinen Unterschied.merge: mehrere Quellen in ein Dataset schreiben, in der angegebenen Reihenfolge.companies: eine Zeile je Firma. Jede zusammengelegte Zeile trägtmergedRows,matchedBy, die gemeinsamen Werte inmatchEvidenceund ihresources; leere Felder werden aus den anderen Zeilen gefüllt.
Feste Regeln statt Vermutungen: Zwei verschiedene Websites werden nie zu einer Firma. Namen mit verschiedener Rechtsform (Müller GmbH, Müller AG) verknüpft der Name allein nie – teilen sie dieselbe Website, greift die Website-Regel. Öffentliche Postfächer (gmail.com, gmx.de, t-online.de), Profile in sozialen Netzen, Kartenlinks und Marktplätze verknüpfen niemanden. Jede nicht gezogene Verknüpfung steht mit Grund im Record SUMMARY.
Von Hand geprüft am 22. November 2026: In einer Liste aus 1.095 echten Zeilen (289 Karten-Einträge, 150 Zeilen mit Impressumsdaten, 656 Stellenanzeigen) entstanden 223 zusammengelegte Gruppen. 208 sind dieselbe Firma, 15 sind zwei Gesellschaften einer Unternehmensgruppe mit gemeinsamer Website, keine legt fremde Firmen zusammen.
Der Lauf arbeitet mit eingeschränkten Rechten (Limited Permissions): Er liest nur die Speicher, die in datasets, keyValueStore und outputDataset stehen. Kosten im Free-Tarif (Stand 22. November 2026): 0,0003 $ je verarbeiteter Zeile in merge und dedupe, 0,001 $ je Zeile in companies, dazu 0,00005 $ je Laufstart; in den Bezahltarifen weniger. Reicht das Kostenlimit, das Zeitlimit oder der Speicher nicht für die ganze Eingabe, ist eine Quelle nicht lesbar oder die Eingabe unbrauchbar, wird der Lauf vor der Arbeit abgelehnt: Er endet erfolgreich ohne Zeilen, berechnet keine Zeile, die Statusmeldung beginnt mit „Rejected: No rows were processed —“ und nennt den nötigen Wert, und SUMMARY trägt "status": "rejected". Fehlen dem Kostenlimit nur eine Zeile oder bis zu 0,5 % der Zeilen, verarbeitet der Lauf trotzdem alles und berechnet bis ans Limit.
FAQ
Which fields does company mode use?
The usual names are found by themselves, in every source separately: companyName, company, organization, employer, title, name for the name; website, domain, homepage for the website; email, emails; phone, phones, telephone; city, postalCode, zip, also inside address, location or locations. A field called url is not taken as the website, because it usually holds the address of the listing. Name a field in companyNameField, websiteField and the others to use it. SUMMARY lists the fields that were used.
A row has a name but no company was matched – why?
A name alone links nothing by default: Elektro Müller exists in many towns. The name counts together with the same postal code or town, or with nameMatch: anywhere. A row whose name sits next to firstName or jobTitle is a person, and its name is not taken as a company name.
Which row stays when rows are merged?
The row from the top-ranked source – the order of datasets, then fileUrls, then recordKeys, then items. With keep: merge its empty fields are filled from the other rows in the same order, and no filled value is overwritten. keep: last and mostComplete choose another row instead.
Can I see what was removed?
Yes. output: duplicates writes the removed rows with their group number, output: all writes every row. unique plus duplicates is always the whole input.
How large can the input be?
dedupe with keep: first and merge read the rows once and keep a few bytes per distinct row in memory – a million rows fit into the default 512 MB (measured, see Limits). companies reads twice and remembers the marks of every row; from about 300,000 rows on it needs 1 GB or more. The run checks this before it starts; when the memory is too small, it is rejected and names the memory to set. On the Apify Free plan your monthly credit is the limit: $5 covers about 16,000 rows in dedupe or 5,000 rows in companies.
Does it work for people, products or URLs too?
dedupe works for any rows: name the fields that identify one. Company mode is built for companies.
Can an AI agent call it?
Yes, through Apify's MCP server or the API. Every field has a default except the sources; the status message and SUMMARY say what was read, merged and left alone.
More from Perceptron Data
| Actor | What it does |
|---|---|
| Imprint & VAT Check | Domains in, company rows out: legal name, address, register number and EU VAT ID checked against VIES (Swiss UIDs excluded) |
| Free Imprint & Contact Check | The same company row, free, for up to 10 websites per run |
| Insolvency & Handelsregister Monitor | Companies in, one row per German company out: insolvency and register notices, EU VAT ID check, open positions |
| Advertiser Check (Google & Bing) | Company list in, one row per company out: Google ads, Bing ads, ad counts, accounts |
| Hiring Companies Germany | Job and place in, one row per hiring company out: open positions, own website confirmed by its Impressum, contact data |
| Arbeitsagentur Jobs | Keyword and place in, one row per job out: employer, salary range, home office, location |
| XING Jobs | Keyword and place in, one row per XING job out: company, salary with its source, employment type, full text |
| PDF to Markdown | Files in, clean Markdown out: real tables, OCR for scans, sections with page numbers |
| Data Source Finder | A source in, the matching actor out – with fields, record count and run cost. Free |
Support
Bug reports are welcome in the Issues tab.
So are feedback, ideas and suggestions for improvement – at any time, in the Issues tab or by e-mail to thom.ehr@gmail.com. Every message is read, and looked into and handled promptly.
Custom Actors: need another source, extra fields or a different delivery? Write to thom.ehr@gmail.com with the source and the data you need, or open an issue on this page. Prices are quoted per project.