Why were boys valued above girls in ancient China?

Boys were more valuable for farming and other manual labor.

Chinese boys had a longer lifespan than girls.

Confucianism emphasized the authority of the father and the ruler, which could only be male. This made the son seem the better gender.

Only boys could serve in government or religious positions.