BlackBerry shares surged more than 4% in early Friday trading, thanks to strong earnings on soft revenue in the fourth quarter of fiscal 2014.

Following the release of fourth-quarter results for fiscal year 2014, shares of BlackBerry Ltd(NASDAQ:BBRY) opened 3.5% higher on Friday. Shares continued to climb in early trading.

BlackBerry's revenue fell 64% year-over-year to $976 million. BlackBerry's quarterly sales sank below $1 billion for the first time since the first quarter of 2008, and analysts were expecting the billion-dollar streak to continue with an average revenue target of $1.1 billion.

On the other hand, BlackBerry reported an adjusted net loss of just $0.08 per share while the Street expected a much larger $0.55 loss per share. The non-GAAP earnings exclude a $382 million adjustment to the fair value estimates of BlackBerry's convertible debentures, which leaves $0.73 of non-cash costs out of the earnings picture.

"I am very pleased with our progress and execution in fiscal Q4 against the strategy we laid out three months ago," said BlackBerry CEO John Chen in a prepared statement. "We have significantly streamlined operations, allowing us to reach our expense reduction target one quarter ahead of schedule. BlackBerry is on sounder financial footing today with a path to returning to growth and profitability."

Looking ahead, BlackBerry plans to maintain a solid cash balance and targets break-even cash flows by the end of fiscal 2015.

Including this morning's surge, BlackBerry shares have now climbed 26% in the past three months. The stock is still down 36% year over year.