Former associate attorney general Webster L. Hubbell has agreed to plead guilty to a felony charge that he misled federal regulators about legal work he performed with first lady Hillary Rodham Clinton on a failed Arkansas real estate development, legal sources said yesterday.

Hubbell will not face any jail time under the plea agreement reached with independent counsel Kenneth W. Starr, the sources said. The agreement also enables Clinton to avoid the prospect of having to testify about her Arkansas business dealings at a trial just as she prepares to launch her campaign for a U.S. Senate seat from New York. For Starr, the deal ends the last pending prosecution in his nearly five-year investigation of the Clintons.

In addition to closing the case stemming from Hubbell's legal work with Hillary Clinton at the Rose Law Firm in the mid-1980s, the plea bargain also ends a tax-evasion case against Hubbell. Hubbell will plead guilty to a misdemeanor charge in that case, sources said.

Hubbell's trial would have been the last of three proceedings against individuals targeted by Starr for allegedly withholding information damaging to the Clintons. Starr failed to win convictions in the first two trials earlier this year, and close associates had warned him that defeat in Hubbell's case could have marked him indelibly as an overzealous and unsuccessful prosecutor, according to sources familiar with the talks.

Prosecutors from Starr's office and Hubbell's lawyers discussed the deal yesterday behind closed doors with U.S. District Judge James Robertson. The plea bargain is due to be formally presented at a hearing Wednesday, sources said. Starr, who has been in Ireland vacationing and teaching, is expected back in Washington for the hearing, which falls on the same day that the statute authorizing independent counsel investigations is set to expire.

Hillary Clinton, though not accused by Starr of any wrongdoing, was mentioned obliquely 35 times in the independent counsel's 40-page indictment of Hubbell. If the case had gone to trial, she was certain to be the subject of extensive testimony about her involvement in the suspicious multimillion-dollar land deal known as the Castle Grande project. In sealed court documents, Starr had listed Clinton as a potential prosecution witness, according to legal sources, raising the possibility of a dramatic courtroom appearance in which the first lady for the first time would have been interrogated in public, under oath, about her controversial professional activities during the time her husband was governor of Arkansas.

Hubbell's plea bargain virtually eliminates the chance that Starr will solicit any further public testimony about the Clintons. The last remaining task Starr faces is to complete reports to Congress about his investigations. Although the independent counsel law expires Wednesday, it allows existing independent counsels to continue their work.

Starr's multiple probes of the Clintons have involved a host of secondary characters, but Hubbell stands out as the most important by far because of his high public office, the length and depth of his friendship with the Clintons and his central role in several of the scandals that have enveloped the White House over the past six years.

First acquainted with the Clintons in the 1970s, Hubbell was then-Gov. Clinton's golfing buddy and Hillary Clinton's law partner. Those close ties led him to be appointed associate attorney general, the number three job at the Justice Department, soon after the president's inauguration in 1993.

But after barely a year in office, Hubbell resigned in the midst of an investigation for defrauding his partners at the Rose firm. Starr, appointed independent counsel in August 1994, immediately began probing Hubbell's career, launching a cat-and-mouse game that continued until yesterday.

In December 1994, Hubbell pleaded guilty to fraud and tax evasion charges brought by Starr stemming from the Rose investigation and accepted a 21-month prison term. As part of his plea, he agreed to cooperate with Starr's office in the Whitewater probe. But after a series of meetings with prosecutors, Hubbell declared that he would provide no more assistance, complaining that his cooperation led only to more investigations.

Starr has argued that Hubbell is protecting his old friends, and prosecutors remain suspicious of $700,000 in consulting fees paid to Hubbell by Clinton allies after he left the Justice Department, publicly raising questions about whether the deals were made to keep Hubbell quiet. Those fees led to the filing last year of the 10-count tax evasion indictment, which accused Hubbell, Hubbell's wife and two longtime associates of conspiring to hide hundreds of thousands of dollars in Hubbell's consulting income.

Hubbell was defiant after the tax case was filed, declaring that Starr's prosecutors "can indict my dog, they can indict my cat, but I'm not going to lie about the president." About six months later, the prosecutors indicted Hubbell again, this time on charges involving Castle Grande.

In the mid-1980s, Hubbell and Hillary Clinton worked together on the Castle Grande project, a money-draining real estate development south of Little Rock. Eventually the project helped trigger the collapse of the Madison Guaranty Savings & Loan, which was owned by the late James B. McDougal, the Clintons' Whitewater business partner.

The Rose Law Firm, with Hubbell as lead attorney, was hired by federal banking regulators in the late 1980s to sue Madison's former accountants after the thrift failed. According to Starr, Hubbell and Hillary Clinton failed to disclose their conflict of interest to the banking officials and then were forced to engage in an extensive coverup of their involvement in the Castle Grande project.

By 1995, both Starr's prosecutors and congressional investigators were focused on the alleged coverup, which they believed involved an elaborate ruse to hide Hillary Clinton's Rose Law Firm billing records. In January 1996, Hillary Clinton became the only first lady to be called before a grand jury, convened by Starr. Starr's office subsequently drafted an indictment of Hillary Clinton but decided not to press forward with a case against her, according to recent testimony by one of Starr's top prosecutors.

Starr brought his 15-count indictment against Hubbell on the Castle Grande matter last November as the House of Representatives moved toward impeaching the president. Starr accused Hubbell of lying to federal regulators and Congress in the coverup. At the time of the indictment, Hubbell proclaimed his innocence.

Robertson, the trial judge in both pending cases, is a Clinton appointee who has been openly skeptical of Starr's tactics. Robertson dismissed the tax case last year, only to have it reinstated on appeal. He also tossed out the opening count in the fraud case but was overturned.