Max H. Karl, a lawyer who invented the modern form of private mortgage insurance, helping to put home ownership within reach for millions of families, died in his sleep yesterday at the Baptist Hospital in Miami. He was 85 and had retired to Miami.

He died of complications after heart surgery, his family said.

In the 1950's, Mr. Karl became frustrated with the time and paperwork required to obtain a home backed by Federal Government insurance, the only kind available at the time. In 1957, using $250,000 raised from friends and other investors in his hometown of Milwaukee, Mr. Karl founded the Mortgage Guarantee Insurance Corporation.

Unlike many mortgage insurers who collapsed during the Depression, Mortgage Guarantee would only insure the first 20 percent of loss on a defaulted mortgage, thus limiting its exposure and creating more incentives for savings and loan associations and other lenders to issue loans only to home buyers who could afford them.

The guarantee was enough to encourage lenders across the country to issue mortgage loans to buyers whose down payments were less than 20 percent of the home's price. The availability of credit helped fuel the home building boom of the 1960's and 1970's. Today, more than 12 percent of the nation's nearly $4 trillion in home mortgages have private mortgage insurance.

"Max had faith that young people would pay for their homes, and he was proven right," said Leon T. Kendall, an executive at the company from 1974 through 1990.

The success of Mortgage Guarantee, known as "magic" or M.G.I.C., allowed Mr. Karl to expand into other businesses. In addition to being the chief executive of Mortgage Guarantee, he founded the first municipal bond insurance company, now called Ambac.

Mr. Karl's quest for a special Internal Revenue Service ruling to exempt some company reserves from taxation made him a small figure in the investigation into influence peddling by Robert G. (Bobby) Baker, the former secretary to the Democratic majority in the Senate. Investigations into Mr. Baker's affairs found that in 1963 he bought 6,000 shares of Mortgage Guarantee stock with the help of a Texas banker shortly before the I.R.S. reversed an earlier policy and granted Mr. Karl the ruling he wanted.

Mr. Karl, who was never accused of any wrongdoing, told a Senate committee that Mr. Baker's first purchase of company stock was in 1959, when shares were for sale only to Wisconsin residents.

Growth of the mortgage insurance business accelerated after 1970, when a Federal housing law said that two Federal agencies, the Federal National Mortgage Association and the Federal Home Loan Mortgage Corporation, could buy mortgages not guaranteed by the Government if they were privately insured.

M.G.I.C.'s fortunes took a turn for the worse after 1982 when Mr. Karl agreed to sell the company to Baldwin United, a fast-growing insurance company that failed the next year. In the scramble to find money to pay for Baldwin United's obligations, the M.G.I.C. that Mr. Karl founded was liquidated, and a new company bearing the same name was created in 1985 with start-up money from managers who included Mr. Karl and from the Northwestern Mutual Life Insurance Company. Mr. Karl helped rebuild the new company and retired at the end of 1989.

Before founding Mortgage Guarantee, Mr. Karl practiced law in Milwaukee from 1933 to 1957. A native of Milwaukee, he graduated from the University of Wisconsin with degrees in economics and law.

He is survived by his wife, Anita Davis; two sons, Robert and Kenneth; a daughter, Karyn Karl Schwade, and nine grandchildren.

Photo: Max H. Karl. (The New York Times, 1981)