Sara Caldwell, Associated Press
FILE - In this Aug. 1, 2014 file photo, Caroline Head, right, clicks through websites on a laptop during a sales tax holiday sale at Best Buy on in Augusta, Ga. Best Buy on Thursday, Nov. 20, 2014 said its revenue edged up in the third quarter, a positive sign for the electronics retailer as the holiday season kicks off.

NEW YORK — Best Buy's third-quarter sales gain is a positive sign for the electronics retailer as the holiday season kicks off.

Both revenue and earnings per share beat expectations, and Best Buy stock rose almost 8 percent in midday trading.

The two-month holiday shopping season is crucial since it accounts for about 20 percent of the retail industry's annual sales. Best Buy CEO Hubert Joly said he expects competition for shoppers to be "intense" this year. Best Buy plans to offer more gifts under $100 but be disciplined about markdowns and promotions, which helps protect profit margins.

But in a call with investors, Joly said the limited supply of some hot products and possible labor strife on the West Coast could hinder sales. He forecast flat revenue for the fourth quarter.

Best Buy is introducing so-called "Black Friday" sales starting this week and rolling out more deals as Black Friday, the busy shopping day after Thanksgiving, nears. The company plans to offer more gifts under $25, $50 and $100 in its stores. And Joly says its deals will be more "balanced and targeted" this year in order to be "thoughtful in terms of return on investment."

Richfield, Minnesota-based Best Buy has been cutting costs and revamping stores to improve results as it faces increased competition from online retailers and discount stores. For example, it has been increasing its speedier "ship from store" deliveries. Last year it shipped from 400 stores, and this year it will ship items from all 1,400 of its stores.

In the third quarter, revenue edged up less than 1 percent to $9.38 billion. Analysts expected revenue to decline to $9.1 billion, according to Zacks Investment Research. Revenue in stores open at least one year, a closely watched performance metric, rose 2.2 percent in the quarter.

Computers, video games, TVs and appliances were the best-selling items. Sales of services, tablets and phones were weaker, despite the flashy launch of Apple's iPhone 6 in September.

Net income after paying preferred dividends totaled $107 million, or 30 cents per share. That compares with net income of $54 million, or 16 cents per share. Adjusted for one-time items, net income totaled 32 cents per share. Analysts expected 25 cents per share.

Shares gained $2.74, or 7.7 percent, to $38.28 in midday trading. The stock had been down about 11 percent since the beginning of the year.