UPDATE 1-United States, Mexico finalize sugar trade deal -sources

(Adds details, background)

WASHINGTON, June 14 (Reuters) - The U.S. Department of Commerce has finalized terms of a closely watched sugar trade pact with Mexico, sources familiar with the agreement said on Wednesday, moving to end a years-long dispute over the sweetener.

Two sources, speaking on condition of anonymity, said the deal was initialed on Wednesday and was expected to be announced later in the day. The news comes a week after U.S. Commerce Secretary Wilbur Ross and Mexican Economy Minister Ildefonso Guajardo announced an agreement in principle.

The agreement, which reworked a 2014 pact, averts steep duties on U.S. imports of sugar from Mexico, the top foreign supplier to the lucrative 11-million-tonne U.S. market. It also prevents the risk of retaliation from Mexico just as the two countries and Canada ready to renegotiate the North American Free Trade Agreement this year.

A spokesman for the Commerce Department did not respond immediately to request for comment.

Last week, the governments announced the deal, despite opposition for the U.S. industry. The U.S. government was expected to move ahead with the deal despite criticism from U.S. sugar producers, who said it left open a "loophole" for Mexican exports.

The two countries have been embroiled in a sugar trade war since U.S. farmers and a cane refiner petitioned the U.S. government in 2014 to protect them from dumping of cheap, subsidized sugar from Mexico. The group said the previous agreement, which set prices and quotas for imports, had not removed harm to the U.S. industry.

(Reporting by Lesley Wroughton in Washington and Chris Prentice in New York; Editing by Chizu Nomiyama and Cynthia Osterman)