Both Virginia Lt. Gov. Richard J. Davis and state Attorney General Gerald L. Baliles contended today that the Democratic Party's nomination for governor was within their grasp.

Davis, who won 56 percent of the delegates selected during party caucuses Saturday, said today he had emerged victorious, but Baliles, who made an unexpectedly strong showing in Fairfax County, said he was certain he would secure the nomination in a final round of delegate selection meetings Monday night.

"We're saying we won," said Davis campaign consultant Rick Rendon. "We surpassed what we needed to win."

Baliles and his aides countered that they had set the stage for their victory with unexpected victories in Fairfax. "My opposition is free to claim victory until Monday night," Baliles told reporters at a news conference today.

The meetings Monday promise to be decisive, both camps agreed. "It's hand-to-hand combat," said Baliles manager Darrel Martin. "It's a challenge that many of us haven't seen for years."

Results released today by state party officials today showed Davis had gained 1,348 of the 1,802 delegates needed for the party's nomination to succeed Gov. Charles S. Robb. Baliles had 956 delegates, 40 percent of those selected Saturday; and 44, or 3 percent, were listed as uncommitted.

Another 1,100 delegates will be selected Monday night in largely rural areas of the state that are generally thought to favor the more conservative Baliles.

Davis will have to capture 454 of them to win the nomination, and Baliles said Davis cannot do that.

Although the lieutenant governor led in the overall results, Baliles scored the only upset Saturday by capturing 42 percent of Fairfax County delegates, winning in several sections of the county that had been considered Davis territory.

"If we had not carried the districts in Fairfax , Monday would be an uphill road," Martin said.

Both camps attributed the attorney general's strong showing there to a last-minute direct-mail and telephone blitz by Baliles as well as an organizational effort that attracted large numbers of "yuppies," young professionals and others political newcomers to his campaign. Davis, a former chairman of the state party, depended more the usual circle of party activists.

Robb cannot succeed himself under Virginia law, and Democrats will select their nominees for governor, lieutenant governor and attorney general at a convention June 7 in Richmond. The winners will face a Republican ticket to be headed by either Richmond lawyer Wyatt B. Durrette or Rep. Stan Parris of Fairfax in the state's November elections.

With Davis claiming an expected landslide victory in his home base of Tidewater and Baliles carrying his home Richmond area, Northern Virginia emerged as one of the most hard-fought battlegrounds. It was critical to what Baliles campaign aides termed their "rural-suburban coalition."

Although both campaigns blanketed the Washington suburbs with telephone calls and direct-mail brochures, Davis supporters say they were outmuscled by Baliles in the three Fairfax magisterial districts Baliles won.

"They out-slicked us," said Sue McGrady, who coordinated the unsuccessful Davis campaign in the Annandale District. Baliles (his name rhymes with smiles) also won in Fairfax's Springfield and Centreville districts, plus Falls Church and Loudoun County.

Davis won all of Arlington's 126 delegates, captured all 72 in Alexandria, won the remaining five Fairfax County districts by wide margins and picked up strong support in Prince William and Stafford counties.

The Baliles campaign targeted potential supporters with nine different direct-mail letters and a 40-unit telephone bank, exceeding its Northern Virginia budget of $150,000, according to Martin.

The campaign was aided by supporters such as Annandale Supervisor Audrey Moore, who, despite years of participation in local Democratic activities, made her debut in state politics with the Baliles campaign.

"I knew he was the underdog," Moore said today, adding that she ignored most of the usual party regulars and concentrated her efforts on rallying the support of political newcomers.

Moore said she persuaded one political newcomer to attend the caucus by agreeing to take over the woman's tax consulting business Saturday while she cast her ballot at the Kings Glen Elementary School.

Two other Fairfax districts carried by Baliles, Springfield and Centreville, are in the newer, rapidly growing areas of the county. "They won the yuppies that had supported Gary Hart," said Centreville Democratic Supervisor Martha V. Pennino, who campaigned for Davis. "Baliles had a very good organization."

Baliles' camp lost Arlington, which, with its 126 votes, could have severely cracked Davis' Northern Virginia base. Even though Davis won the county with only a slim margin, the entire delegate block was committed to his campaign because of the county party's "winner-take-all" rules.

The party delegate selection rules vary in each jurisdiction, with some areas such as Prince William County allotting delegates proportionately and others allowing the candidate with the majority of votes to claim the entire block.

Davis spent today crisscrossing the state by airplane, attempting to muster critical support for Monday night, while Baliles was in Roanoke and Richmond.

Baliles strategists played down the jubilation they displayed Saturday night. "There's still work to be done on Monday," Baliles said. "I wouldn't make any premature claims. I think it's important to continue the momentum."

In contrast, the subdued mood of Saturday night had lifted at the Davis headquarters. Campaign aides today flashed color-coded charts before reporters, explaining their elaborate schemes for winning in what had been conceded to be Baliles territory.

Voting lines remained blurred in some major areas. Saturday night's results showed no monolithic support among blacks, who can make up about one-third of the party's statewide voting strength. While Davis was expected to win the support of blacks, their allegiance appeared split between the two candidates.

And while labor union support was expected to help Davis in Northern Virginia, Tidewater and far Southwestern Virginia, Baliles won delegates in the part of Prince William County where state AFL-CIO president David Laws resides.

In the uncontested race for the party's lieutenant governor nomination, state Sen. L. Douglas Wilder of Richmond won 1,311 votes. The remaining 280 delegates remained uncommitted. And the only candidate for attorney general, state Del. Mary Sue Terry of Patrick County claimed 1,133 delegates, with 528 uncommitted.

Both Baliles and Davis have said they expect Wilder and Terry to win nomination easily at the convention.