Tokyo stocks rose 0.37 percent on Tuesday after eurozone talks produced a bailout deal for Athens, easing fears over a Greek bankruptcy.
The Nikkei 225 index, which opened the session in negative territory, added 34.36 points to 9,423.30 by the closing bell, while the Topix index of all first-section shares gained 0.27 percent, or 2.10 points, to 781.60.
"The worst-case scenario (of talks breaking up) was avoided," Fumiyuki Nakanishi, general manager of investment & research at SMBC Friend Securities, told Dow Jones Newswires.
After marathon talks in Brussels, the eurozone and the International Monetary Fund agreed to unlock 43.7 billion euros ($56 billion) in loans for Athens and grant significant debt relief for decades to come.
The "laborious" negotiations, according to IMF head Christine Lagarde, are intended to see Greece's debt-to-GDP ratio fall from an estimated 144 percent to 124 percent by 2020, and "substantially below 110 percent" by 2022.
Greece, struggling to stay afloat amid a series of unpopular austerity measures, has been waiting for an injection of international loans to avoid defaulting on its upcoming debt repayments.
"The decision will certainly reduce the uncertainty and strengthen confidence in Europe and in Greece," said European Central Bank chief Mario Draghi.
In forex trading, the euro made gains over Monday trade with the 17-nation currency buying $1.2990 and 106.76 yen in Tokyo, after briefly topping $1.30 for the first time in about a month.
That was stronger than $1.2971 and 106.38 yen in New York trade, although the euro eased slightly after the Greece announcement as the deal was widely expected among traders who have pushed up the unit recently.
The dollar meanwhile gained to 82.25 yen from 81.98 yen following remarks by Japan's main opposition leader Shinzo Abe, who made renewed calls Tuesday for aggressive easing by the Bank of Japan, which tends to weigh on the yen.
Abe is the front runner to become Japan's next prime minister following December 16 elections.
In Tokyo stock trade, Japan Airlines rose 4.21 percent to 3,710 yen as investors picked up the stock ahead of the busy holiday season.
Fast Retailing, operator of the Uniqlo cheap chic clothing chain, rose 1.94 percent to 18,380 yen.
Nippon Steel & Sumitomo Metal Corp., the world's second-biggest steelmaker, fell 2.04 percent to 192 yen after Fitch downgraded the firm's credit rating on Monday, citing a global industry downturn and its weak financial position.
Investors were also keeping an eye on a budgetary impasse in Washington where the so-called fiscal cliff of spending cuts and tax hikes is due to come into effect on January 1, and likely to send the US economy into recession unless a new spending deal is reached.