I split the pool of subjects into two strata, males and females. Then I randomly assign the males to the treatment and control groups, and then randomly assign the females. The prior stratification of the pool into male and female subjects does not reduce the validity of the experiment. That discrepancy is the error of the experiment. Matching often helps to reduce such error.
Experiments assume that the extraneous factors are distributed among the subject pool.
Very often the subject pool is small, and the randomization procedure leads, by chance, to experimental and control groups that are quite different. Pretesting grew up to handle this problem. The pretest allows one to assess how different the two groups are. They should be the nearly same on the dependent variable, but sometimes they are different to an extent larger than what would be due to sampling error alone. When this happens, one does not estimate the effect by the difference between the posttest means of the experimental groups.