Amniocentesis is a prenatal diagnostic procedure that involves extracting a small amount of amniotic fluid from the uterus to test for genetic conditions, fetal infections, and other abnormalities. This procedure is usually performed between the 15th and 20th weeks of pregnancy.