Joe L. Allbritton, the millionaire Texas banker who came here four years ago to rescue the then-faltering Washington Star, has agreed to sell the newspaper to the billion-dollar Time Inc. publishing empire.

The surprise deal, announced "in principle" yesterday, was worked out in closely guarded negotiations between Allbritton and Time President James R. Shepley. They described it as designed to bolster The Star's long-term prospects. Allbritton said he would stay on at The Star as its publisher and chief executive officer for at least five years.

"It's been clear all along that The Star needed more than I alone could give it," Allbritton said in a prepared statement that he read at a half-hour news conference. "It needed exactly what Time Inc. can give it - a great deal of publishing expertise to strengthen promotion and advertising, a greater editorial resource, writers, pictures, information."

Whether the unexpected change in The Star's ownership would lead to rapid shifts in the newspaper's formal, operations or contents appeared uncertain. Allbritton and Time officials asserted that no immediate changes were planned. "We're quite pleased with the format of The Washington Star," Allbritton remarked at his news conference.

Time would pay Allbritton $20 million for the newspaper and would also assume The Star's outstanding debts, according to terms of the deal outlined by Star and Times officials yesterday. The only major debt mentioned by these officials yesterday was an $8 million mortgage on The Star's Southeast Washington headquarters. Other sources said, nevertheless, that Time will assume several millions of dollars in additional Star liabilities.

The announcement of The Star's prospective sale, which is apparently still subject to further negotiations over financial arrangements and approval by the board of directors of Time Inc., prompted mixed reactions among Star employes and outsiders familiar with the newspaper business.

Labor union leaders at The Star and Star staff members, who have been buffeted by repeated changes in The Star's organization in recent years, appeared to greet the proposed Time takeover with cautious optimism.

"I hope Time Inc. can provide the necessary operating revenue for The Washington Star so it can survive," Bill Boarman, president of International Typographical Union Local 101, which represents Star printers, remarked.

Allbritton, 53, would retain control of a substantial communications business, even after the proposed sale of The Star is concluded. He will remain as chairman of Washington Star Communications Inc., now the newspaper's parent corporation. Allbritton has been the sole owner of the corporation and of all its communications enterprises.

Washington Star Communications Inc. also owns WJLA-TV which Allbritton has agreed to swap in a multimillion-dollar deal for an Oklahoma City television station. The transaction was approved by the Federal Communications Commission last month, but the FCC decision has been appealed in court.

Washington Star Communications Inc. also owns television stations in Lynchburg, Va., and Charleston, S.C., and daily newspaper in Westfield Mass., Union City, N.J., and Patterson, N.J.

In addition to acquiring The Star, Time Inc. would, under the proposed deal, also take over The Washington Star Syndicate, which distributes articles by Star writers and a number of prominent columnists.

Allbritton said that he expects The Star's sale to be concluded on Feb. 19, three days after the next Time board of directors meeting. Donald M. Wilson, Time vice president for corporate and public affairs, said that Time officials regard a Feb. 19 closing as possible, though they are not certain arrangements can be completed so rapidly.

Both Allbritton and Time officials indicated that Time would pay for the newspaper in a combination of cash and promissory notes. Wilson said it would be in "cash or notes." Allbritton said it would be in "cash or cash equivalent." He described a cash equivalent as a short-term note, government bond or savings account.

Allbritton and Time officials gave differing accounts of how the deal came about, though it was clear that it resulted from tightly guarded talks between the two companies' top executives, Allbritton and Shepley.

Time, according to several officials, had sought for many years to acquire a daily newspaper in a major metropolitan area and had at various times discussed purchase of The Star.

According to Time vice president Wilson, Allbritton first broached the notion of selling The Star to Time Inc. in a casual conversation with Shepley about a year ago. "It started slowly," Wilson said. "It was very casual at the beginning."

At his news conference, Allbritton gave the negotiations a different slant. He said that "serious" negotiations had been underway for only about a week and indicated that Time Inc. had initiated the sale, commenting, "It was at their request."

Neither Allbritton nor Time officials would disclose Allbritton's prospective salary as Star publisher, though Allbritton said it would be "commensurate" with his responsibilities. It is apparently among outstanding subjects for negotiation. Time president Shepley is considering a proposal by Allbritton that Shepley become chairman of The Star's new board of directors. Time vice president Wilson said Shepley would be a Star board member, even if he decides not to accept its chairmanship.

Time Inc., a giant in its field, publishes the weekly news magazine Time, Sports Illustrated, People, Fortune and Money. It also has book, record and cable television operations, among others. Its forest products subsidiary is Temple-Eastex. The corporations had more than $1 billion in revenues last year.

The Star, founded in 1852, had been run for more than a century by members of the Noyes, Kauffman and Admans families when Allbritton took his initial steps to take over the newspaper in 1974. At the time, Allbritton has said, The Star was losing about $1 million a month.

September 1976 - Radio stations WMAL-AM and WMAL-FM (now WRQX) of Washington, sold to the American Boradcasting Company for $16 million, one of the highest prices ever paid for radio properties. The FCC approved the sale in December 1976.

For many years, The Star was the dominant Washington daily, overshadowing three other papers, including The Post, in advertising and circulation. A shift began, however, in 1954 when The Post bought The Washington Times-Herald. In 1972, when The Star merged with the Daily News, both papers together trailed The Post in circulation. The Post still exceeds The Star in advertising and circulation.

The Star's average circulation for the six months ending last Sept. 30 was 349,475 on weekdays and 336,680 on Sunday - a decrease from its previous circulation average of about 375,000 daily.

When Allbritton first took on the job of revitalizing the apparently foundering Star newspaper, he said he would allow himself only about three years to have The Star paying its own way. In a 1975 interview, he said, "I thought, and I still think, that if you can get the economics of this paper on an even keel, and if you can get the broadcast facilities on a consolidated basis, the whole thing could be an attractive financial package."

Allbritton had already gained a reputation as a financial wizard in a wide range of undertaking, including a Houston bank, an insurance company, a chain of mortuaries and many other investments.

By his own recent Allbritton's reign at The Star has been largely successful. In an interview last November he termed The Star's survival "the miracle of the publishing industry." He said he had trimmed The Star's losses to $1,289,000 in its most recent fiscal year and he predicted the newspaper would yield a "tiny" profit during the current fiscal year, which began Oct. 1.

He summarized his four years at The Star in a statement published on the newspaper's front page yesterday. Noting that The Star was financially "on the ropes" when he took over the newspaper, Allbritton added:

"All that has changed The Washington Star has been saved, not just for its employees, but for citizens of Washington. Its vast debts have been paid. Many of its advertisers have returned."

"To help achieve these things," he added in the statement. "I invested millions of my own money beyond the original purchase price. I also invested every fiber of my imagination." At the news conference, he said his own investment in the newspaper had been close to $30 million in addition to the amount he initially paid for the newspaper, some $35 million.

Yesterday's announcement of the proposed Star sale was greeted with a range of views, both skeptical and optimistic, from business executives here and elsewhere.

Katherine Graham, chairman of The Washington Post Co. and publisher of The Post, Time Inc. to the Washington newspaper field. We have the greatest respect for their publishing skill, and feel sure that The Washington Star will benefit greatly from its association with that company. We're pleased, as well, that Joe Allbritton, who has shown himself to be a fair and able competitor, will remain as publisher."

The Washington Post Co., as numerous officials noted yesterday, owns Newsweek magazine, Time magazine's principal rival.