SAN FRANCISCO — David Drummond, the chief legal officer of Google’s parent company, Alphabet, and one of its most senior executives, is leaving the internet giant amid an investigation into his relationships with women who worked at the company.

In an email sent to employees at Google and Alphabet, Mr. Drummond, who joined Google in 2002, said he planned to leave Alphabet at the end of the month. He said that it was the “right time for me to make way for the next generation of leaders” in light of Larry Page and Sergey Brin, Google’s founders, stepping back from day-to-day roles at the company.

His resignation comes more than a year after 20,000 Google employees protested the company’s handling of sexual harassment and inappropriate workplace relationships. The protests were a public reckoning for a permissive work culture that had existed since the company’s early days — exemplified by generous exit packages for senior executives even after they were accused of sexual misconduct.

In recent months, Mr. Drummond had come to symbolize how — despite the company’s assertions that it would no longer tolerate such actions — some powerful men in the technology world accused of inappropriate behavior often weathered the storm, landing new jobs or keeping their old ones.