It remains a blip in the rear-view mirror of longtime leader Fox News, but CNN at long last has some ratings news to smile about.

In Nielsen estimates for the second quarter, CNN surged well above its alarmingly low numbers of last year at this time to leapfrog MSNBC in both total day and primetime rankings. CNN's sibling HLN also showed nice improvement and similarly surpassed MSNBC, which ran fourth for the first time in eight years.

In primetime, CNN placed second among the cable newsies for the quarter, topping MSNBC in both total viewers and adults 25-54 for the first time since 2009. In total day, this is the first time since 2005 that both CNN and HLN have surpassed MSNBC.

Looking at the numbers, Fox News led total-day among cable news networks in the key news demo of adults 25-54, but CNN closed the gap. FNC's 240,000 viewers in the demo (down 6% from last year) was followed by CNN (162,000, up 69%), HLN (142,000, up 48%) and MSNBC (123,000, down 5%).

In adults 25-54 among all cable networks for the quarter, FNC ranked 17th in total day while CNN placed 31st. In primetime, FNC was 27th and CNN was 34th.

In total viewers for the quarter, Fox News (1.18 million) nearly outdrew its three news competitors combined in total-day averages (CNN's 476,000, HLN's 393,000 and MSNBC's 361,000). And in primetime, where "The O' Reilly Factor" remains the dominant program, FNC (2.21 milion) did outperform the combined average viewership of CNN (733,000), MSNBC (660,000) and HLN (569,000).

Among all networks in primetime, Fox News ran fifth for the quarter in total viewers -- behind USA, TNT, Disney and History.

Key to the growth for CNN were top program "AC360," which had its best showing in both total viewers (803,000) and the 25-54 demo (271,000) since moving to the 8 o'clock hour nearly two years ago. Also, "Piers Morgan Live" had its largest audience (720,000) since its first quarter in early 2011.

Recent afternoon entry "The Lead With Jake Tapper" beat MSNBC during the quarter in both total viewers (595,000 vs. 429,000) and showed healthy gains over the time-period averages on CNN a year ago.

Fox News continued to dominate the cable news program rankings. In the adults 25-54 demo for the second quarter, the net's "The O'Reilly Factor" (456,000), "Hannity" (389,000) and "On the Record with Greta Van Susteren" (341,000) were the top programs. And in total viewers, it was "The O'Reilly Factor" (2.86 million), "Hannity" (2.11 million) and "The Five" (2.10 million).