THE RECENT presidential campaign eroded custom after custom, but in the end the legitimacy of the results and the sanctity of the peaceful transition of power were reaffirmed. Or so it seemed.

Once the electoral college vote was clear, Hillary Clinton graciously conceded to President-elect Donald Trump, and President Obama promised to work for a smooth transition. Neither Democrat emphasized the fact that Ms. Clinton won the popular vote. Russian government interference in the campaign is a legitimate subject of concern, but Ms. Clinton properly chose not to use it to cast doubt on the outcome of the election. Mr. Trump reciprocated her positive tone.

Then Jill Stein, the Green Party presidential nominee, pressed for recounts in a handful of swing states, based on thin suspicions of election tampering. The Clinton campaign indicated that it saw little reason to initiate a recount or any other kind of inquiry, but announced it would join in anyway so its representatives would be present for any official review. The likely results of Ms. Stein’s recount effort are twofold: enhancing her fundraising and sowing unfounded doubts in Americans’ minds about the integrity of the election.

Yet it was Mr. Trump’s reaction that was the most corrosive. Following the Clinton camp’s decision to join in the recount, the president-elect lashed out on Twitter on Sunday. “In addition to winning the Electoral College in a landslide, I won the popular vote if you deduct the millions of people who voted illegally,” Mr. Trump wrote, offering zero evidence for the incendiary charge. The president-elect appeared to be repeating a debunked story circulating on conspiracy-peddling right-wing websites that claims millions of noncitizens voted.

Mr. Trump is the president-elect. He above all others bears responsibility to safeguard and defend the integrity of the nation’s democratic government. Instead, he illogically attacked the very system that resulted in his victory. For those who hoped that as president-elect he would be slower to take offense than he had been as candidate, and less willing to trade in lies, the tweet came as one more disappointment. Mr. Trump’s overreaction suggests he is not prepared for the responsibilities of the presidency or the scrutiny that comes with it.

The nation, in fact, does have a voting problem, but it is not the imaginary fraud that Mr. Trump conjures. Rather, it is a system that makes it too difficult for citizens to cast their votes. Registration procedures are unnecessarily restrictive. Early voting opportunities are needlessly limited. Lines are way too long. Names are too easily purged from voter rolls. Election equipment lacks paper trails in some states. Yet, if Mr. Trump’s preoccupation with phantom voting fraud is any indication, his administration may spend a lot of time making ballot access worse, not better. The integrity of the country’s democracy would suffer for it.