Marissa Mayer must be pretty proud of herself.
She announced a deal Tuesday to spinoff Yahoo's stake in Alibaba that will bring in big bucks for shareholders -- something she's been working on since taking the helm of Yahoo in 2012.
Investors cheered the announcement, sending the stock soaring as much as 8% in after-hours trading.
What's key about the deal is that it is tax free. The move could save shareholders $16 billion in tax costs, Mayer said on a call with investors.
Yahoo already earned $6.3 billion from selling part of its stake in Alibaba (BABA) when the company went public last year.
Related: Hedge fund still pushing Yahoo-AOL deal
Alibaba made a killing that week, raising more money than Facebook (FB) or Visa (V)did after their IPOs. It was like Christmas in September for Yahoo shareholders.
Yahoo (YHOO) still has 384 million shares of Alibaba (BABA), about a 15% stake. Those shares will be transferred to a new, publicly traded company called SpinCo, and be distributed among Yahoo investors.
The tax-free transaction maximizes "the value of our Alibaba investment for our shareholders," Mayer said.
After the spinoff, which is expected to complete by the end of 2015, Yahoo will have returned nearly $50 billion dollars of value to its shareholders from its Alibaba investment, based on Tuesday's closing share price.
Related: Jack Ma made $18.5 billion this year
Meanwhile, Yahoo Tuesday reported quarterly results that were so-so. Revenue and profit were both lower than the same quarter in the previous year. But revenue from mobile rose 23% -- it was the first time the company reported that as a separate item. The performance shows "stability in the core business," Mayer said.