A young California lawyer and the woman he is living with talked at a dinner party recently about making it legal - with a contract, not a preacher.

Actor Lee Marvin discovered last December that the absence of a contract may not get him off the legal hook with the woman he had lived with for six year. In a landmark decision by the California Supreme Court she won the right to sue him for support and a share of the wealth he accumulated while they were living together.

Some singles bars in San Francisco are advertising that they have a notary public on duty wntil 2 a.m. to certify any cohabitation contracts that might be drawn up on the back of a napkin.

" [WORD ILLEGIBLE] are jumping around right now trying to figure out how to persuade their partners to sign contracts," said Stephen Adams of San Francisco, editor of the California Family Law Report, at the American Bar Association convention here.

And, needless to say, a panel of lawyers who discussed this trend today at the convention favored it.

There has been a dramatic increase during the past decade in the number of American men and women who have set up households without getting married.

Census Bureau studies - always considered conservative - found 1.3 million unmarried American couples last year, twice as many as in 1970 and three times as many as in 1960.

"Suddenly," said Carol S. Bruch, University of California law professor, "college students, doctors, lawyers, all strata of socieyt- people with money and property - were doing it."

With the increased affluence of the new breed of unmarried couples, lawyers have begun getting into the act.

Beverly Ann Groner, family law specialist from Bethesda, theorized that "most people form informal alliances because they don't want formal contracts. If they did, they would get married."

But Elaine Rudnick Sheps, a New York attorney specializing in family law, contradicted her by saying an increasing number of unmarried couples are coming to her for legal advice - including her daughter, who is living with a man.

Adams, the editor of the California Family Law Report, called the Lee Marvin decision "the most far-reaching family law case of 1976."

"I believe that this is the beginning of a legal trend that will spread and take hold in our laws," said Los Angeles attorney Riane Tennenhaus Eisler. "The California Supreme Court decision to legally recognize and enforce the reasonable expectation of nonmarital partners is a response to contemporary social realities."

As a result of the Marvin decision, said Adams, "our newly christened 'nonmarital partners' will come into our offices and our courts for judicial recognition of their reasonable expectations in dissolving their nonmarital relationships."

This, he said, raises all sorts of legal questions:

What about homosexual couples or nonsexual roommates who form "a de facto economic union?"

What about a couple that marries after living together? If the marriage breaks up, does the division of property start from the time they were wed or from the time they began living together - especially since they may have made most of their big purchases, such as a house and furniture, before marriage?

According to the Family Law Report, television producer Freddy Fields has agreed to pay $6,000 a month support to his wife of five months before the divorce case comes to the court in the fall. The agreement was reached after her attorney argued she was entitled to greater property rights because they had lived together for four years before they were married.

"We're obviously going to have a lot of fun litigating these questions," said Adams.

There is one other major question that bothered the family law experts today. How would they get paid?

Adams said he has taken on four cases of unmarried couples breaking up, on a contingency basis where he would get a percentage of the settlement the same as a lawyer in an accident or medical malpractice case.

This traditionally has been considered unethical in divorce cases because the attorney is considered to have a duty to try to reconcile the couple to save the marriage.

"Reconciliation is as important in de facto families [unmarried couples living together] as in any other family, but I think we are going to have to sacrifice that to allow one of the parties to sue," said Bruch, the law professor.