For the first time in more than two years, Yahoo edged Google on a list of most visited websites in the U.S. in July, a small victory for Chief Executive Officer Marissa Mayer and her turnaround efforts at the Sunnyvale Web pioneer.

The combination of all Yahoo sites attracted about 196.6 million unique monthly visitors in July, topping all of Google's sites, which had 192.3 million, according to online research firm comScore.

It's the first time since May 2011 that Yahoo beat out Google for the top spot on the comScore monthly rankings of top 50 Web properties, said comScore spokesman Andrew Lipsman. Since 2009, the top spot in the ranking has belonged to either Google or Yahoo, he said.

In July, Microsoft sites were third at nearly 175 million and Facebook was fourth at 144.7 million.

Mayer was hired away from Google a year ago to turn around Yahoo. She has since directed a stream of improvements to various services and sites, such as makeovers to the company's photo-sharing service, Flickr, and its mobile weather app.

Yahoo also has been on a buying spree, picking up companies like social blogging service Tumblr. That acquisition wasn't what boosted Yahoo to the top. ComScore counted Tumblr's numbers separately, and it came in at No. 29 on the list with 35.9 million unique monthly visitors.

Still, comScore's numbers measure only website traffic and don't include one important and growing category - mobile.

"Mobile is a key driver of business and usage of both Facebook and Google, so to compare these businesses to Yahoo without incorporating mobile doesn't really present a full picture," said Clark Fredricksen, vice president of the research firm eMarketer.

On the advertising revenue side, Google is still trouncing the competition.

According to eMarketer, Google's $15 billion in U.S. ad revenue in 2012 stood far above second-place Yahoo's $3 billion. Facebook was third at $2.2 billion, but was closing in quickly.

Yahoo will have to keep visitors coming back to move the needle on advertising revenue. One attempt to generate traffic is a 30-day marketing campaign surrounding a new logo the company says it will reveal Sept. 4. The campaign features one new version of Yahoo's purple logo posted on its sites each day.

Polar, a Los Gatos company that runs a public opinion app and website, has been running a poll comparing the new logos with the old. So far, only one new design has won, although by a resounding 75 to 25 percent.

Yahoo stock closed at $27.90 per share Thursday, up 3.1 percent from Wednesday.