- Home
- Resources
- Integrations
- Compare Datasets
n8n Compare Datasets nodeConfigure Compare Datasets in n8n.
The n8n Compare Datasets node takes two input streams and sorts every item into four branches. Seven parameters decide which fields make two items a match, what happens when the values differ, and how duplicates are handled. Useful the day two systems stop agreeing.
Verified Trustpilot reviews · AI, automation & growth agency
What does the n8n Compare Datasets node actually do?
The Compare Datasets node compares two inputs for changes. You give it a field that identifies the same record on both sides, and it splits the result across four outputs: In A only Branch for data that exists only in the first input, Same Branch for items that agree, Different Branch for items that match on the key but differ elsewhere, and In B only Branch for data that exists only in the second input.
Comparison runs in two stages. First n8n checks the values of the fields you picked in Fields to Match across both inputs. When those keys line up, it then compares all the other fields inside the two items to decide whether they belong in the Same branch or the Different branch. That second stage is why a field that changes on its own, like a timestamp, can push perfectly healthy records into Different until you tell the node to ignore it.
Three shapes of work cover most of what this node is used for. A reconciliation: yesterday's export on input A, today's on input B, and the Different branch becomes your change log. A one way sync: rows pulled from Google Sheets on one side, records from an API on the other, with In B only feeding the creation step and In A only feeding the archive step. A deduplication pass: two lists of the same people, Multiple Matches set to Include First Match Only so a repeated record is not counted twice.
Pick the right node for the job. Merge combines two streams into one, this node keeps them apart and tells you how they differ. If routes items on a condition you already know, while Compare Datasets works out the condition for you by looking at the other input. Once the four branches exist, Switch is often what sends each one to the right follow up.
The limits are worth knowing before you build. The node needs two inputs, so both sides have to be fetched first, and it runs on the items it receives rather than opening a workflow on its own: a Schedule Trigger or a Webhook goes in front of it. Matching is done on field names you type as text, which means a rename upstream breaks the match silently. And the comparison is structural, not semantic: two spellings of the same city are simply different values. For a deeper look at where n8n fits, the n8n review covers the platform itself.
Which parameters shape the comparison?
The Compare Datasets node has 7 parameters. For each one: the node as you configure it in n8n, what the parameter changes, and our field notes.
Parameters index
Fields to Match
mergeByFieldsWhat you see in n8n
Notes & use cases
This is where the comparison starts. You name one field per input, and n8n treats items sharing that value as the same record before it looks at anything else. Select Add Fields to Match to compare on several keys at once.
Key parameters
- Input A Field: the field name taken from input stream A, typed as text, for example
id. - Input B Field: the matching field on input stream B, which can carry a different name when the two systems disagree on naming.
When There Are Differences
resolveWhat you see in n8n
Notes & use cases
Once two items match on the key but disagree on the rest, this selector decides what the Different branch actually contains.
Key parameters
- Use Input A Version: treats input stream A as the source of truth.
- Use Input B Version: hands that role to input stream B.
- Use a Mix of Versions: output uses different inputs for different fields. It opens Prefer, where you pick the main source, and For Everything Except, the field names pulled from the other side, comma separated.
- Include Both Versions: output contains all data, with a more complex structure.
Fuzzy Compare
fuzzyCompareWhat you see in n8n
Notes & use cases
Turned on, the comparison tolerates small type differences between fields. The number 3 and the string '3' are then treated as the same, where a strict comparison would send the pair straight to the Different branch. Leave it off when a type change is exactly what you are hunting for.
Key parameters
- Fuzzy Compare: a switch on the main panel, off by default, applied to the whole comparison rather than to one field.
Fields to Skip Comparing
options.skipFieldsWhat you see in n8n
Notes & use cases
Some fields move on their own and say nothing about the record. This option lists the ones that shouldn't be included when checking whether two items are the same, as text, separated by commas.
Key parameters
- Fields to Skip Comparing: field names to ignore, for example
updated_at, updated_by. In the documented example, two datasets matched onperson.languagecome back as different untilperson.nameis added here, after which n8n returns them as matching.
Fuzzy Compare
options.fuzzyCompareWhat you see in n8n
Notes & use cases
The same type tolerance is also reachable from the node Options collection, which you open with Add option. Every option you add shows up as one more field in the panel, and the ones you leave out keep their default value, so adding it here is how you make the setting explicit next to the other comparison tweaks.
Key parameters
- Fuzzy Compare: whether to tolerate small type differences when comparing fields, the number 3 and the string '3' being treated as the same.
Disable Dot Notation
options.disableDotNotationWhat you see in n8n
Notes & use cases
By default a field name written parent.child reaches into a nested object. Turn this option on and that stops: the name is read literally instead. Off, which is the default, keeps the nested reference working.
Key parameters
- Disable Dot Notation: whether to disallow referencing child fields using
parent.childin the field name.
Multiple Matches
options.multipleMatchesWhat you see in n8n
Notes & use cases
Duplicate data is the normal case, not the exception, and this selector says what to do with it. The default is Include All Matches.
Key parameters
- Include All Matches: output multiple items if there are multiple matches, which on the documented fruit example gives three items in the Same Branch tab.
- Include First Match Only: only ever output a single item per match. Two items come back instead, the repeated apple counting once.
Need help automating Compare Datasets with n8n?
A person reads every message.
Compare Datasets in n8n, answered
01Is the Compare Datasets node included in n8n?
02What credentials does the n8n Compare Datasets node need?
03What are the limits of Compare Datasets in n8n?
04When should you use Compare Datasets instead of Merge?
05n8n or Make for comparing two datasets?
Get our weekly integration tips.
No spam. Unsubscribe anytime.


