Babies inherit their eye color from both parents, through a complex interplay of genes. While it's true that a baby's eye color is often similar to one parent's, the specific combination of genes from both parents determines the final outcome.
Eye color is a complex trait, not simply a matter of dominant and recessive genes as previously thought. Multiple genes contribute to eye color, and some genes are more influential than others. For example, the OCA2 gene is strongly associated with eye color, but other genes can influence the exact shade.
Because of this intricate genetic process, a baby's eye color can sometimes surprise parents, even with seemingly predictable combinations. For example, two blue-eyed parents can have a brown-eyed child.