Microsoft was founded in 1975 by Mr. Gates, then 19, and a friend, Paul Allen, who is now less actively involved in the company. Mr. Gates, who as a teen-ager had developed a previous computer programming business, dropped out of Harvard and wrote a version of the Basic computer language for one of the first personal computers. Selected by I.B.M. Microsoft's big break came five years ago, when its MS-DOS - which stands for Microsoft disk operating system - was chosen by I.B.M. for use on its personal computer. As I.B.M. soared to prominence in the personal computer business, so did Microsoft, in a relationship that one Microsoft official recently described as ''five years on a raft.'' There was always the risk that I.B.M. would go its own way. But the agreement signed recently between I.B.M. and Microsoft seems to remove this threat for the next few years at least.

Last year, MS-DOS accounted for about 20 percent of Microsoft's revenues, while other systems software, mainly programming languages, totaled 30 percent. In applications software, which accounted for most of the rest of the revenues and is expected to grow fastest, Microsoft has done only moderately well.

It got a late start in the applications software market for I.B.M. and faced entrenched, highly specialized competitors. The I.B.M. computer version of Microsoft Word, the company's word processing software, trails programs by Multimate, Micropro International and I.B.M. itself, according to audits of computer stores by IMS America, a market research firm.

Microsoft was also hurt by its reputation for bringing products to market behind schedule and full of ''bugs'' or errors. In a letter in the latest issue of Macworld magazine, for instance, a reader gripes about finding ''15 bugs and 7 shortcomings'' in the initial Macintosh version of Microsoft Word. ''Word is typical untested Microsoft software,'' he said.

To improve its production process, Microsoft has changed its management. Mr. Gates, while still chief executive and clear leader of the company, has no one reporting directly to him. That allows him to concentrate on the direction of the company while leaving day-to-day management to others, particularly the president and chief operating officer, Jon Shirley, former head of the Tandy Corporation's personal computer merchandising.

The company has also moved quickly into software for the Macintosh computer, and now dominates that market. It is also expanding overseas, where its Multiplan spreadsheet outsells 1-2-3.

But Microsoft is still in search of a hit product. One contender, coming this month, is Excel, a spreadsheet program for the Macintosh that Mr. Gates expects will become Microsoft's best seller. Excel is more like 1-2-3 than Lotus's own program for the Macintosh, which is called Jazz and has sold below expectations.