President Barack Obama said Tuesday (July 14) that the nuclear deal with Iran “makes our country and the world safer and more secure.”

“The United States, together with our international partners, has achieved something that decades of animosity has not — a comprehensive, long-term deal with Iran that will prevent it from obtaining a nuclear weapon,” he said.

The president made an early-morning statement from the White House after Iran and world powers reached a historic accord for Tehran to curb its nuclear program in exchange for the easing of economic sanctions.

He said that the deal was built on verification, not trust, and he said that walking away would increase the likelihood of a “nuclear arms race in the most volatile region of the world.”

“Put simply: No deal means the chance of more war in the Middle East,” he said.

Obama threatened to veto any legislation that threatens the implementation of the deal, and he cautioned Congress: “We don’t make deals like these with our friends.” He mentioned American arms-control deals with the Soviet Union decades ago.

Tehran has been negotiating with the U.S., Britain, France, Germany, Russia and China for years, with diplomats extending a series of deadlines in hopes of arriving at a workable plan.

One senior White House official cautioned that while the agreement was undoubtedly historic, it was not an “immediately transformative” moment.

“We’re years away from judging its success,” the official told NBC News.

The U.S. president spoke after Iran’s Foreign Minister Javad Zarif called the agreement a “historic moment” and a “win-win solution” with the potential to usher in a “new chapter of hope” in relations.

“We are reaching an agreement that is not perfect for anybody but it is what we could accomplish and it is an important achievement for all of us,” he said early Tuesday. “Today could have been the end of hope on this issue but now we are starting a new chapter of hope.”

Israel — a key U.S. ally — slammed the deal, with Prime Minister Benjamin Netanyahu saying it gave Iran a “”sure path to nuclear weapons” while Science Minister Danny Danon said the deal was “dangerous for the entire free world.”

However, the EU’s chief negotiator stressed the terms were “balanced” and respected the interests of “all sides.”

“It’s not only a deal,” Federica Mogherini said at a press conference formally announcing the accord. “It’s a good deal.”

The comprehensive agreement — which runs more than 80 pages — was clinched after marathon overnight negotiations in Vienna.

It involves limiting Iran’s nuclear production for 10 years and Tehran’s access to nuclear fuel and equipment for 15 years in return for hundreds of millions of dollars in sanctions relief. However, the sanctions would not be lifted until Iran proves to the International Atomic Energy Agency that it has met its obligations under the terms of the deal.

The agreement includes the provision of a “snap back” mechanism that could lead to the reinstatement of sanctions within 65 days if Iran violates the terms of the deal, according to officials.

The head of the International Atomic Energy Agency confirmed Iran also has signed a roadmap with his organization to clarify outstanding issues.

One senior White House official cautioned that while the agreement was undoubtedly historic, it was not an “immediately transformative” moment.

“We’re years away from judging its success,” the official told NBC News.

United Nations Secretary General Ban Ki-moon said he warmly welcomed news of the deal, praising the determination, commitment and “courage” of the negotiators.

“This is testament to the value of dialogue,” he said in a statement. “I hope — and indeed believe — that this agreement will lead to greater mutual understanding and cooperation on the many serious security challenges in the Middle East. As such it could serve as a vital contribution to peace and stability both in the region and beyond.”

The agreement still faces a vote in Congress, although it is unclear whether Republicans and some Democrats who object to the deal will actually be able to override the decision.

Even before details of the deal were released, Republican Sen. Ben Sasse said it could trigger a “descent into chaos.”

“The administration just lit the fuse for a nuclear arms race in the Middle East,” he said in a statement. “We all know Iran’s neighbors will not sit idly as the world’s largest state-sponsor of terror becomes a nuclear-threshold state.”

“This deal abandons America’s historic bipartisan commitment to preventing nuclear proliferation, and instead begins the era of managed proliferation—a descent into chaos and an even more dangerous world.”

Iran’s moderate President Hassan Rouhani has staked a large share of his political future on a successful outcome of talks. He stands to be one of the biggest winners out of the agreement.