WASHINGTON—Secretary of State John Kerry, in an often contentious Senate hearing, told lawmakers Wednesday the U.S. isn't negotiating a “legally binding” agreement with Iran, meaning future presidents could choose not to implement the accord.

The back-and-forth between the GOP and the Obama administration over the deal has grown heated within recent weeks. On Monday, a group of 47 GOP senators sent an open letter to Iran’s leaders asserting it could quickly change or discard any agreement once President Barack Obama leaves...