WORCESTER - U.S. Rep. James P. McGovern, D-Worcester, declared victory Tuesday night in his bid to win a 12th term representing the 2nd Congressional District.

Mr. McGovern's victory over Grafton Republican Tracy L. Lovvorn was decisive. With 26 percent of districts reporting he held a 63 percent to 37 percent lead over Ms. Lovvorn.

The Associated Press soon after called the race in Mr. McGovern's favor. According to Associated Press totals, Mr. McGovern was at around 106,000 votes to Mr. Lovvorn’s 50,000.

Mr. McGovern did not shy away from tying his victory, and his mandate for his 12th term, to a repudiation of President Donald Trump.

“It’s no secret to anyone here that they last two years have been difficult,” Mr. McGovern told supporters at El Basha on Park Avenue Tuesday night.

He said a sense of values and treating others with respect is part of what drove people to the polls.

“This campaign, and this victory, is about decency,” Mr. McGovern said.

He said that if the Democratic Party comes through with a victory in the U.S. House of Representatives, it will provide a check on the president, and said the body will start solving problems.

“I hope we get to set an example for what decency, integrity, and civility is all about,” Mr. McGovern said.

An activist and staunch liberal who has been fiercely critical of the administration of Mr. Trump, Mr. McGovern is a ranking member of the powerful House Rules Committee.

Ms. Lovvorn, a physical therapist, painted Mr. McGovern as a career politician who has overstayed his welcome and lost touch with the concerns of his constituents in the district, which includes Worcester and a wide swath of Central Massachusetts. She said he was part of the problem of the dysfunction in government.

Mr. McGovern's campaign easily out-raised and out-spent Ms. Lovvorn. The latest campaign filings with the Federal Election Commission show that from January through Oct. 17, Mr. McGovern's campaign showed total receipts of $1,082,205, and as of last month his campaign had more than half a million dollars in cash on hand. Ms. Lovvorn's campaign showed $36,275 in total receipts for the same time period, with just $5,443 in cash on hand.