DNA base sequencing
The DNA of organisms can be compared by looking at the order of the bases (As, Ts, Gs and Cs) in each.
Closely related species will have a higher percentage of similarity in their DNA base order. For instance, humans and chimps share around 98%, while humans and mice share about 85%.