Paternity testing is a scientific method used to determine the biological relationship between a child and a potential father. It is commonly used to establish paternity for legal reasons, such as child support, custody, inheritance, and immigration. The test is typically performed by collecting DNA samples from the child, the potential father, and sometimes the mother to compare their genetic markers and determine if there is a biological relationship.