The ultrasound at 20 weeks may be inaccurate if the technician is not able to get a good picture of the baby. Also, the baby's legs may get in the way of determining the sex, however, it is usually possible to get him or her to move. The earliest an ultrasound can possibly determine the gender of a fetus is 12 weeks. Most doctors won't attempt to determine the gender until 16-20 weeks. Unlike amniocentesis, ultrasound genderizing isn't an exact science. Depending on the way the baby lays, it can be difficult to see the genitals.