Protestant and Catholic hard-liners scored big gains Friday in Northern Ireland's elections to the British Parliament, reflecting shifts in power that could threaten the province's 1998 peace accord.

Protestant hard-liner gains were eroding the position of David Trimble, the embattled Protestant leader of Northern Ireland's joint Catholic-Protestant government.

The Irish Republican Army-linked Sinn Fein party, meanwhile, had won or was leading in four races – an unprecedented showing since it began contesting British general elections in 1983. Sinn Fein held two seats going into the contest.

The power-sharing coalition created in the 1998 pact joins the territory's four biggest parties, two Irish Catholic and two Protestant. The contest for Northern Ireland's 18 seats in Parliament demonstrated the tussle for dominance within each of the camps.

Trimble's Ulster Unionist party was trying to fend off the Democratic Unionists, who oppose Trimble's compromise policies and were hoping a strong showing in the vote could force him out of office.

Largely completed counts showed Ulster Unionists fighting closely with their hard-line rivals in several districts – including, against all expectations, Trimble's own.

Trimble did wrest back a seat held by an outspoken Protestant opponent of the 1998 pact in Northern Ireland's wealthiest district, the North Down suburbs east of Belfast. His successful candidate, Lady Sylvia Hermon, became the first woman to hold a Northern Ireland seat in Parliament since Catholic civil rights firebrand Bernadette Devlin in 1970.

But elsewhere, Ian Paisley's Democratic Unionists were ascending to levels previously unseen in Northern Ireland. In North Belfast, the Democratic Unionists' Nigel Dodds trounced the sitting Ulster Unionist member, Cecil Walker, by 16,718 votes to 4,904.

Paisley cruised to easy victory in North Antrim, the seat that the anti-Catholic evangelist has held since 1970, and from the podium led his supporters in singing hymns and a chest-thumping rendition of "God Save the Queen."

In East Londonderry, his party's candidate upset the area's long-sitting Ulster Unionist, William Ross, who was actually hostile to Trimble and his compromising policies. South Belfast re-elected its Ulster Unionist incumbent, Martin Smyth – but he, too, is a Trimble critic who has already tried to oust his leader once.

With several of Northern Ireland's 18 seats still to be declared, the Democratic Unionists said the results demonstrated that a growing majority of Protestants was hostile to sharing power with Sinn Fein.

"Protestants are sickened at the sight of terrorists at the heart of our government. We will do everything we can to expel this cancer from the body politic," said Dodds in North Belfast.

Sinn Fein leader Gerry Adams registered a crushing 20,000-vote majority in his West Belfast constituency. The party's other incumbent, Martin McGuinness – who caused a furor earlier this year when he publicly acknowledged his role as a top IRA leader – increased his own majority by several thousand in Mid-Ulster.

Even more strikingly, Sinn Fein was in the lead in two hotly contested rural districts along Northern Ireland's border with the Republic of Ireland. Both were previously held by Ulster Unionists.

If elected, all Sinn Fein members would continue to refuse to attend debates or vote in Parliament in London, on the grounds this would require they give an oath of allegiance to Queen Elizabeth II.

Sinn Fein's surging vote came at the expense of the Social Democratic and Labor Party, which had traditionally won most Catholic votes as it opposed IRA violence. That issue has faded in importance among Catholics ever since the IRA called cease-fires in 1994 and 1997.

SDLP leader John Hume, who shared the 1998 Nobel Peace Prize with Trimble, easily defended his seat in Northern Ireland's second-largest city, Londonderry, beating the Sinn Fein chairman Mitchel McLaughlin by a 2-to-1 margin.

But his party's wider standing versus Sinn Fein has been eroding ever since Hume inspired the Northern Ireland peace process back in 1993 by opening negotiations with Sinn Fein's Adams, then an isolated figure. He declined to comment directly on his party's slippage to Sinn Fein, particularly its loss of younger voters.