Ashton Carter made the comments en route to Israel, the first leg of a tour of the Middle East.
He is seeking to ease concerns of a key ally who has been one of the most vocal critics of the nuclear deal.
But Mr Carter admitted he was "not going to change anybody's mind in Israel".
Instead, he sought to stress that the US' willingness to protect Israel was undiminished.
"One of the reasons why this deal is a good one is that it does nothing to prevent the military option," Mr Carter told reporters.
"This is a good deal," he added. "It removes a critical element of danger, threat and uncertainty from the region."
Under the deal between Iran and six world powers, Iran must curb its nuclear programme in exchange for sanctions relief.
The Israeli Prime Minister, Benjamin Netanyahu, called the agreement an "historic mistake" that clears the way for Iran to make nuclear weapons.
In an interview on Sunday, Mr Netanyahu dismissed suggestions that the US could boost military aid to Israel following the accord, saying that would imply it agreed with the deal.
"I guess the question you have to ask yourself is, if this deal is supposed to make Israel and our Arab neighbours safer, why should we be compensated with anything?'' he told ABC.
Mr Carter arrived in Tel Aviv on Sunday. He is due to meet his Israeli counterpart Moshe Yaalon on Monday before holding talks with Mr Netanyahu on Tuesday.
He will then travel to Saudi Arabia,  Iran's main regional rival, and then on to Jordan, for talks on tackling the Islamic State militant group.
Military action could still be used to prevent Iran developing a nuclear bomb, despite the agreement struck this week, the US defence secretary has said.