How are duplicate errors handled

Historically the applications I have worked on send errors the old fashion way, via emails and there are tons of duplicates but sometimes there are slight variations in the errors e.g. depending on the version deployed.

I want to understand how an error is marked a duplicate, what are the factors that are taken into consideration etc.

Also, historically what would be a very rough ballbark figure of the % of unique errors to duplicates when using sentry to manage 100+ different types of applications.