The deal is a victory for the Caucasus Mountain nation, whose president, Mikhail Saakashvili, has sought to move the country out of the shadow of Moscow and toward deeper economic and military relations with the United States and Europe.
Troops and equipment will begin to be pulled out of the military base at the southern city of Akhalkalaki by year's end, and then similar withdrawals with start from the Black Sea port of Batumi, said Russian Foreign Minister Sergey Lavrov, who signed a joint statement with Georgian counterpart, Salome Zurabishvili. About 3,000 troops are stationed at the two bases.
Russia committed itself to finishing the withdrawal by the end of 2008, according to the pact, the text of which was posted on the Russian Foreign Ministry Web site.
The agreement is "an important and constructive step," Zurabishvili said. "We have achieved to goal which we have long been working
Lavrov also said the accord would "help further develop our relations."
Georgia had accused Russia of procrastinating the withdrawal in order to keep a presence in the country the Kremlin regards as part of its historic sphere of influence. Earlier this year, Georgian officials indicated they might declare the bases illegal in 2006 if negotiations bogged down.
Russia's two bases in Georgia are holdovers from the Soviet era; two other bases were closed this decade.
Russia and Georgia also have sparred over Russia's close relations with the governments in Abkhazia and South Ossetia two regions that broke away from Georgia during wars in the 1990s.
Russia in turn has watched with dismay as Saakashvili pursues closer relations with the West and boosts military cooperation with the United States.
In the second program of its kind, US military instructors are training about 2,000 Georgian troops who will serve in international peacekeeping operations. Georgia also has more than 850 soldiers and other military personnel serving in Iraq as part of the US-led military effort there.