» more from Business

Female CEOs are outpacing their male colleagues in pay, although they remain vastly outnumbered in the top echelons of American companies.

Last year, the median pay for women CEOs rose to $15.9 million, a 21 percent gain from a year earlier, according to a study by executive compensation data firm Equilar and The Associated Press. That compared with median pay for male CEOs of $10.4 million, which was down 0.8 percent from 2013.

Marissa Mayer, the head of Yahoo, was the highest-paid female chief executive in the Equilar/AP pay study. Her compensation was almost double that of the next-highest earner on the list—Carol Meyrowitz of discount retailer TJX Companies.

Still, there is a big caveat: There are far fewer female CEOs than males among large U.S companies. The study of 340 CEOs included 17 women.

Tom Merton | Getty Images