In a huge coup that is sure to shock Silicon Valley, Yahoo! (YHOO) has recruited Google (GOOG) exec Marissa Mayer to become the struggling technology company’s latest CEO.

The hire instantly makes Mayer, who famously designed Google’s iconic search homepage, one of the most powerful women in the tech world.

Mayer, 37, resigned from Google on Monday afternoon by telephone and starts at Yahoo! on Tuesday.

"I am honored and delighted to lead Yahoo!, one of the internet's premier destinations for more than 700 million users,” Mayer said in a statement.

Shares of Sunnyvale, Calif.-based Yahoo! rallied 2.14% to $15.98 in extended trading after The New York Times broke the surprising news.

While she “had an amazing time at Google” for 13 years, ultimately “it was a reasonably easy decision” to take Yahoo's top job, Mayer told the Times.

Mayer, who was also tapped to sit on Yahoo!’s board and serve as the company’s president, joined Internet powerhouse Google back in 1999 as its 20th employee.

In recent years Mayer oversaw Google’s Local, Maps and Location Services, a division that includes Google Maps and Zagat. She spearheaded a slew of Google’s successful product launches, including Google News and Gmail.

“Marissa is a well-known, visionary leader in user experience and product design and one of Silicon Valley's most exciting strategists in technology development,” said Yahoo! co-founder David Filo.

Yahoo! has struggled to overcome fierce competition in the display advertising world from Google and more recently Mark Zuckerberg’s Facebook (FB).

Mayer takes over for Tim Morse, the company’s chief financial officer and interim CEO.

Yahoo! has seen a carousel of figures pass through its C-Suite, including co-founder Jerry Yang who left in 2009 and former Autodesk (ADSK) CEO Carol Bartz who was fired in 2011.

Yahoo! was forced to accept the resignation of Scott Thompson in May after it became clear the former CEO of eBay's (EBAY) PayPal fibbed about his academic credentials.

“The Board of Directors unanimously agreed that Marissa's unparalleled track record in technology, design, and product execution makes her the right leader for Yahoo! at this time of enormous opportunity," said Fred Amoroso, Yahoo! chairman.

Mayer, who received a pair of degrees from Stanford, also sits on the board of directors at Wal-Mart (WMT). She has been recognized for the past four years as one of the 50 Most Powerful Women in Business by Fortune.

Follow Matt Egan on Twitter @MattMEgan5