In a San Francisco office an hour’s drive from some of the biggest companies in Silicon Valley, Sephora has managed a corporate feat that would make the leaders of Google Inc., Apple Inc. and Facebook Inc. envious: a majority of the cosmetics retailer’s technology workers—62%—are women.

At a time when technology companies are struggling mightily to attract and retain women with computing and engineering skills, the beauty retailer’s tech staffing is notable not only for the numbers but also for the relatively simple way it got there.

Women hold 23% of roles in the technical ranks at the top 75 Silicon Valley companies, according to the U.S. Equal Employment Opportunity Commission. A report from the commission attributes the scarcity of women in those roles to inhospitable work cultures, isolation, a “firefighting” work style, long hours and a lack of advancement.

At Sephora, women make up the majority of its 350-person digital and engineering staff and hold all but one of the roles on its six-person digital executive leadership team. Women lead everything from digital marketing and customer experience in apps to back-end programming of the company’s e-commerce systems.

Though large tech companies employ several times as many engineers as Sephora, its share of female digital talent is worth noting. Managers say the retailer has managed to attract technical women by recruiting with an eye toward candidates’ potential rather than specific skills, encouraging hiring managers to take risks and ensuring that job performance is assessed fairly.