Katherine Archuleta said she would step down on Friday to help the department "move beyond the current challenges".
Authorities suspect that Chinese-based hackers targeted the computer systems of the OPM, which acts as the personnel office of the federal government.
Initially the OPM said four million workers were affected by the breach.
However, the department disclosed on Thursday that the data of more than 20 million people, including current and former employees, may have been compromised.
Authorities in Beijing have publicly denied any involvement.
Ms Archuleta resignation comes a day after Democrats and Republicans in Congress called for her to step aside as the scope of the data breach expanded significantly.
Among the data targeted were forms used to vet potential employees of federal agencies including as the CIA and branches of the military.
The stolen data includes health and financial information, criminal records, and the names and addresses of government employees and their relatives.
Experts are concerned that the sensitive information could be used to blackmail US agents.
Source: OPM news release
Last month, US intelligence chief James Clapper said China was the "leading suspect" in the massive data breaches.
His comments came after three days of high-level talks in which China and the US agreed to a "code of conduct" on cyber security issues.
US Democratic presidential hopeful Hillary Clinton said China was "trying to hack into everything that doesn't move in America".
But China has dismissed claims of involvement as "irresponsible and unscientific".
The director of the US Office of Personnel Management (OPM) has resigned after a massive data breach involving more than 20 million people.