In his first moments as president-elect, Donald Trump finally went presidential.

“To all Republicans and Democrats and independents across this nation, I say it is time for us to come together as one united people. It’s time,” he said. “I pledge to every citizen of our land that I will be president for all Americans, and this is so important to me.”

Trump’s victory speech yesterday was his most gracious and inclusive, and even included praise for his opponent: “Hillary has worked very long and very hard over a long period of time, and we owe her a major debt of gratitude for her service to our country.”

The statements were a somewhat reassuring prelude to his term after a frequently terrifying run for the job.

Trump’s shocking victory served notice to the Democrats he defeated and the Republican Party he co-opted that it is the people — not the parties, the permanent political infrastructure, the big-name celebrities and the gatekeepers in the media — who now have the power.

Scarred by the populist surge of Sen. Bernie Sanders in the primaries, Hillary Clinton fell victim to another grass-roots movement in the election.

advertisement | advertise on newsday

Trump beat 16 experienced candidates for the GOP nomination. As House Speaker Paul Ryan said in offering congratulations yesterday, Trump heard “a voice out in this country that no one else heard.”

Trump saw what Republicans could not: a base abandoned by a GOP establishment which preached that hard work would bring prosperity — even as the party let good jobs be shipped overseas, and let new workers come here to labor on the cheap. Those mostly white working-class voters could no longer bring themselves to support GOP candidates who promised tax cuts for the rich and slashes in the social safety net that allows increasingly dispossessed workers to keep their heads above water. And Trump’s words were a siren song for suburban and rural voters who felt uncomfortable with a rapidly changing culture.

Unfortunately, much of what Trump was willing to say to get attention demeaned women, Hispanics, people with disabilities and African-Americans. That those words didn’t disqualify him is the most frightening thing about this election, along with Trump’s seeming disinterest in policy issue details and his ham-handed approach to delicate foreign relations.

Trump was lucky to run against Clinton. She won the popular vote, but to the Obama coalition voters she needed for an extra margin of support, she represented business-as-usual in politics: wealth achieved via political fame, cozy relationships with corporate fat cats, mealymouthed answers to tough questions, and an unending stench of dubious decisions and secrecy.

Trump’s gracious acceptance speech, and inspiring speeches yesterday from Clinton and President Barack Obama, sought to quiet nerves and soothe the anger felt by half the population.

“We owe him an open mind and a chance to lead,” Clinton said. Later, she added, “I believe we are stronger together and will go forward together.”

Obama’s words evoked the best aspects of his presidency: “We have to remember that we’re actually all on one team. This is an intramural scrimmage. We’re not Democrats first. We’re not Republicans first. We are Americans first. We’re patriots first.”

Trump needs to remember that, as do his scariest, most racist, least inclusive and most hateful followers.

advertisement | advertise on newsday

We can have hope for what Trump can accomplish and still fear the side of him, and the aides around him, that allowed so much ugliness in his campaign. Those who worry about his worst impulses can take comfort from our government’s system of checks and balances. Our founders built a structure to guard against a concentration of power.

Republicans who have now tied themselves to him will control Congress. Trump has the opportunity and the responsibility to get a lot done, such as his job-creating infrastructure programs, but GOP leaders have an even greater responsibility to stop him if he veers off course.

Campaign promises aside, it would be a disaster if on the first day in office, the administration costs tens of millions people their health insurance by ending Obamacare with no viable replacement, devastates the environment by kneecapping the Environmental Protection Agency and subsidizing coal mining, deports parents of children born here legally, cancels trade deals and tears up international treaties.

To anybody who doubted Trump’s talents, his accomplishment in this unlikely election to the presidency should suggest he has plenty. He knew whom to listen to and when to get this done. He knew what the people wanted and how they felt. He heard what others could not and was able to speak to what others failed to address.

But now he must be so much more if he is to succeed. He must be inclusive, patient, thoughtful, studious and measured, not petty and contemptuous. He must choose cabinet members strong enough to disagree with him. He must be open about his personal finances and his extensive businesses. He must reject the darker desires of those who helped him to power.

advertisement | advertise on newsday

Above all, on Jan. 20, he will take an oath to “preserve, protect and defend the Constitution of the United States.”

That’s nonnegotiable.

— The editorial board