Calculators

Sørensen–Dice Similarity Calculator

Calculate the Sørensen–Dice coefficient and set overlap counts for two sets privately in your browser.

Enter two sets separated by commas, semicolons, or new lines. Spaces within an item are preserved; surrounding spaces and empty entries are ignored. Matching is case-sensitive and duplicates count once. One set may be empty. The calculation runs locally in your browser; your values are not uploaded or stored.

Your Dice similarity will appear here.

Measure shared items with the Dice coefficient.

The Sørensen–Dice coefficient is D = 2 × |A intersection B| / (|A| + |B|). For A = apple, banana, cherry and B = banana, cherry, date, two items are shared and each set has three unique items: D = 4/6, approximately 0.666667 (66.6667%). Identical nonempty sets score 1; disjoint sets score 0. Dice dissimilarity is 1 − D; it does not satisfy the triangle inequality and is not a mathematical metric. For nonempty union, Dice relates to Jaccard similarity J by D = 2J / (1 + J). Duplicate items count once. Matching is case-sensitive after trimming surrounding whitespace; Apple differs from apple and 01 differs from 1. Separate items with commas, semicolons or newlines. Spaces inside an item are retained; quoted CSV delimiters are not supported. Empty entries are ignored. One empty set and one nonempty set score 0; two empty sets are undefined in this calculator. Each set supports 10000 entries including duplicates and 200000 characters. Results display up to 12 significant digits. This compares exact unweighted set membership, not frequencies or semantic meaning. All processing stays in your browser.

Frequently Asked Questions

Everything you need to know about this tool, how it works, and privacy.

How is Dice similarity calculated?

Divide twice the unique intersection size by the sum of the two unique set sizes. Two shared items between sets of three items each give 4/6, approximately 0.666667.

How does Dice differ from Jaccard similarity?

Dice divides twice the intersection by the sum of set sizes. Jaccard divides the intersection by the union. For Jaccard score J, Dice is 2J / (1 + J); both range from 0 to 1.

Do duplicates or capitalization affect the result?

Duplicates count once. Matching is case-sensitive after trimming surrounding whitespace. Separate items with commas, semicolons or newlines; spaces inside items are preserved. Each set supports 10000 entries and 200000 characters. Quoted CSV delimiters are not supported.

Can I compare empty sets?

One empty and one nonempty set score 0. Two empty sets produce a zero denominator, so this calculator reports the result as undefined.

Is Dice dissimilarity a distance metric?

The reported dissimilarity is 1 minus the Dice coefficient. It does not satisfy the triangle inequality, so it is not a metric. Calculations stay in your browser.