There is no way to know for sure how anyone gets autism.
The current understanding of Autistic Spectrum Disorder is that it has no single cause, cannot be explained by any one gene, and that most cases result from problems in early brain development caused by environmental risk factors interacting with autism risk genes.
Environmental risk factors can include genetic mutation, advanced parental age at the time of the conception (both mom and dad), chemicals in the pregnant mother’s environment, like air pollution and pesticides, or maternal lifestyle factors like diet, nutrition, and alcohol and tobacco use, or medical factors such as certain viral infections of the mother during her pregnancy, or diabetes during her pregnancy, or low birth weight, premature birth, or difficult delivery of the baby. Please keep in mind that these factors alone are not enough to cause autism.
Autism has been shown to run in families. Parents who have one child with ASD have a 2%-18% chance of having a second child with ASD, thus early screening is important.
Recently, researchers have identified many rare gene changes or mutations associated with ASD. There are over 100 known autism risk genes. Genetic testing is recommended, as it may provide more resources for treatment and support.