The best book I've read on this topic is "Why Men Earn More", written by a former director of the National Organization of Women. The book is essentially a guide showing women how to earn more money, offering a huge example of interesting statistics. For example, people working 45 hours a week earn about 44% more than those working 40 hours per week, and women tend to work many fewer hours than men, while preferring jobs that end mentally at the end of the shift. I'd recommend the book to anyone interested in a more nuanced view.
Long story short, the pay gap can be explained almost entirely by the male tendency to work more hours, at harder and more dangerous jobs, while being more flexible (e.g. Willing to move, travel nonstop, Work in uncomfortable conditions, etc.). Further, men do this largely to acquire and provide for women and families, so women tend to benefit from this. In a lifetime, men tend to spend at least an order of magnitude more on finding a mate than women.