By Alan Rappeport

WASHINGTON — Treasury Secretary Steven Mnuchin said on Saturday that he believed the United States and China were nearing the final stage of trade negotiations, moving closer to what he said would be the biggest change in the economic relationship between the countries in 40 years.

Mr. Mnuchin’s note of optimism comes as the world’s two largest economies are racing to end a protracted trade dispute that has resulted in damaging tariffs and business uncertainty and provided a drag on the global economy.

“We’re hopeful that we’re getting close to the final round of concluding issues,” he told reporters on the sidelines of the spring meetings of the International Monetary Fund and World Bank.

Mr. Mnuchin again repeated his claim that the biggest obstacle to a trade deal — how to enforce the agreement — is nearly settled. The United States has been pushing China to agree to a mechanism that would allow Washington to impose tariffs on Chinese goods if Beijing reneges on certain parts of the deal.

On Saturday, Mr. Mnuchin said that the United States and China would both have the authority to enforce commitments that are agreed to, indicating the ability for Beijing to exert some control in the future as well.

“We’ve already agreed there’s a big component of this that there will be real enforcement on both sides,” he said, “including a detailed enforcement office on both sides with significant resources.”

At a congressional hearing in February, Robert E. Lighthizer, President Trump’s top trade negotiator, described a complex enforcement mechanism under discussion that aimed to ensure China would live up to its promises.

Mr. Lighthizer said at the time that China had agreed to regular meetings at the levels of office director, vice minister and minister that would allow the United States to keep tabs on China’s behavior and air complaints from companies about unfair business practices. If China did not keep its promises, the United States would respond “proportionally but unilaterally.” The implication was that the United States would respond with tariffs.

American officials have also been pressing China to agree not to retaliate against the United States if it reimposes tariffs on Chinese goods. China has been reluctant to agree to a one-sided enforcement mechanism, viewing it as infringing on its sovereignty and giving Washington too much power over its economy.

“If complaints are real, we may have to use tariffs to deal with them, and we’re asking the Chinese not to retaliate,” Larry Kudlow, the director of the National Economic Council, told the Fox Business Network in March when discussing enforcement of a deal.

People who have been closely tracking the talks cautioned that enforcement continued to be an obstacle that remained unsettled because China and the United States had not agreed on the specifics of penalties.

“The problem with the so-called enforcement issue has to do with finding a mechanism that allows punishment for violations of the agreement,” said Michael Pillsbury, a China scholar at the Hudson Institute who advises the Trump administration. “That hasn’t been done yet.”

On Saturday, Mr. Mnuchin would not clarify whether the United States and China had agreed on an enforcement mechanism that would allow only Washington to respond with tariffs as punishment for violating the deal.

“I want to be careful in answering that because I don’t want to get into the details of the negotiations and specifically on tariffs,” he said.

But Mr. Mnuchin said that he expected enforcement of the trade pact to be reciprocal.

“There are certain commitments that the United States is making in this agreement and there are certain commitments that China is making, and I would expect that the enforcement agreement works in both directions,” he said. “We expect to honor our commitments and if we don’t, there should be certain repercussions, and the same way in the other direction.”

Mr. Mnuchin would not specify what commitments the United States was making. Mr. Trump has been pushing China to open its economy and end practices that he says have put American companies at a disadvantage.

A spotlight on the people reshaping our politics. A conversation with voters across the country. And a guiding hand through the endless news cycle, telling you what you really need to know.SIGN UP

The deal under discussion would require China to end its longstanding practice of requiring American companies to hand over valuable technology as a condition of doing business there and would open portions of China’s economy more liberally. The two sides have discussed China’s buying more than $1 trillion worth of goods over the next several years to help lower the trade gap between the countries.

To get China to the negotiating table, Mr. Trump slapped tariffs on $250 billion worth of Chinese goods. That punishment has begun to pinch China’s economy and Beijing’s negotiators are demanding that at least some of the tariffs be removed as a condition of any final deal. It remains unclear how many — and at what point — those tariffs will be lifted.

The Treasury secretary made clear that there were still provisions that need to be completed and that a deal was not yet certain.

Officials from the United States and China are in regular contact by telephone, Mr. Mnuchin said, and they are determining if additional face-to-face meetings are needed.