The announcement came after telephone talks with Greek counterpart, Alexis Tsipras, on Tuesday.
The Greek government has spent 27 years fighting with Macedonia over the use of the name, which references ancient Macedonia and by association its famous leader, Alexander the Great.
Speaking at a news conference in the Macedonian capital, Skopje, Zaev described the deal as a "historic agreement of the century".
"We got a fair deal..."
In Skopje, meanwhile, Macedonian President Gjorge Ivanov said earlier in the day that he remained opposed to a constitutional change that would likely be included in the draft deal, to provide an assurance that the name change was permanent and binding for domestic and worldwide use.
In Athens, Greek Prime Minister Alexis Tsipras called the deal "historic".
Previous comments from the Macedonian side have indicated that solutions could involve adding a modifier to the country's official name, such as "Upper" or "Northern" to satisfy Athens, although nationalists in Macedonian have opposed such concessions.
Antoine Griezmann refuses to clarify where he will play next season
It was hoped Griezmann would clarify his future at the press conference, but he refused to be drawn into a discussion. There's still a week to go [before the World Cup ].
The two prime ministers are expected to sign the agreement over the next weekend.
European Union and North Atlantic Treaty Organisation officials, meanwhile, welcomed the announcement from Tsipras and Zaev, calling it a "historic" deal. Macedonia will also amend its constitution to reflect the change as part of the deal.
"We wholeheartedly congratulate Prime Ministers Alexis Tsipras and Zoran Zaev for their determination and leadership in reaching this historic agreement between their countries, which contributes to the transformation of the entire region of South-East Europe", Hahn and Mogherini said in a joint statement.
Macedonia's new name will be put up for a referendum, to be held in autumn.
The name dispute has poisoned relations between the two countries since Macedonia's independence from Yugoslavia in 1991 and has prevented Macedonia from joining global institutions such as North Atlantic Treaty Organisation and the European Union.
Athens contends that the name Macedonia represents a territorial claim over Greece's northern province, also named Macedonia.