TEL AVIV—Israeli Prime Minister Benjamin Netanyahu said the agreement between Iran and six world powers on Tehran’s nuclear program is a “historic mistake for the world.”

“Wide-ranging concessions were made in all of the areas which should have prevented Iran from getting the ability to arm itself with a nuclear weapon,’’ Mr. Netanyahu said. “The desire to sign an agreement was stronger than everything else.”

The Israeli leader has long opposed the talks, saying an accord would leave Iran with the ability to build a weapon within weeks.

Mr. Netanyahu also said lifting economic sanctions on Iran would give Tehran hundreds of billions of dollars to boost support its allies in the Middle East that are also Israel’s enemies.

“From the initial reports received, it is already possible to say that this agreement is a historic mistake for the world,” Mr. Netanyahu said.