AOL (AOL) swung to a third-quarter loss on weaker subscription revenues and restructuring charges that could not be wholly offset by an uptick in advertising, however its performance still surpassed Wall Street’s expectations.

The New York-based Internet and media giant posted a net loss of $2.6 million, or 2 cents a share, compared with a year-earlier profit of $171.6 million, or $1.61 a share, in the same quarter last year.

Analysts polled by Thomson Reuters were expecting a steeper loss of 6 cents a share.

Revenue for the operator of AOL.com, Moviefone and MapQuest was $531.7 million, down 6% from $564.2 million, a year ago, due to declines in subscriptions. The results still beat the Street’s view of $524 million.

The revenue’s decline was AOL’s lowest in five years. The company’s chief executive, Tim Armstrong, said on Wednesday that the 28% and 15% improvement in party network and global display advertising revenue, respectively, substantially closed “the gap to revenue and eventual profit growth.”

Search and contextual revenue fell 15%, its slowest decline in two years, which is a reflection of lower revenue from unprofitable distributions deals exited last year and softer global search revenue.

Consumer usage climbed year-over-year with the help of The Huffington Post, which surpassed 35 million monthly unique visitors last quarter, and its other media groups.

However, the slowing declines were offset by lower subscription revenues, which tumbled due to a 15% drop in domestic AOL-brand access subscribers, as well as continued investments in the company’s local news service Patch and other strategic areas, which led to a $7.1 million restructuring charge. 

Revenue per subscriber fell 3%.

Follow Jennifer Booton on Twitter at @Jbooton