The primary function of placental villi is to facilitate the efficient exchange of nutrients, gases, and waste products between the maternal and fetal circulations. This is achieved through the extensive surface area provided by the villi, which allows for maximal contact with maternal blood. They also play a role in hormone production, such as human chorionic gonadotropin (hCG), which is essential for maintaining pregnancy.