The way to establish legal paternity of a child is to first take a DNA test with respect to the child and parent. The test will ascertain paternity. Once such is established, the father files a petition with the court  in the county where the minor resides attaching the test results seeking an order of paternity. For such, a family law attorney may need to be consulted.