Bill Gates stood down as CEO of Microsoft in January 2000 at the age of 44.
Prior to his resignation, Microsoft was engaged in major legal battles with the Justice Department over accusations that the company was using its monopoly on operating systems to control the market. It would have been a stressful ordeal. Microsoft being broken into multiple companies was a very real prospect. In November 1999, the District Court ruled that Microsoft had established a monopoly and had taken actions to crush threats to that monopoly. In June 2000, the Court concluded that Microsoft should be broken into two separate companies. This was of course appealed, and eventually the dispute was settled in an agreement in November 2001.
Commentators at the time suspected that the Department of Justice action took all the fun out of the job for Gates, and that he wanted to go out on a high note rather than a low one. Thus, it’s likely why he left the post of CEO in the middle of the litigation to focus on tech as the new chief software architect. This role enabled him to focus on tech, the thing he enjoys most, and reduce distractions from other responsibilities he had as CEO.