By Rex Crum, MarketWatch

SAN FRANCISCO (MarketWatch) -- Apple Inc. shook off its early struggles to post strong gains Wednesday, and Twitter Inc. also got a boost on what became an upbeat day for the tech sector.

Apple (AAPL) ended the day with a gain of 3% at $101 a share in the wake of the company's Tuesday presentation of the new iPhone 6 and iPhone 6 Plus, as well as its anticipated Apple Watch smartwatch and a new mobile-payment service called Apple Pay at a company event.

While many Wall Street analysts were upbeat about Apple's announcements, Andy Hargreaves, of Pacific Crest Securities, cut his rating on Apple's stock to sector perform, or the equivalent of neutral, from outperform.

Twitter (TWTR) shares climbed 4.5% to close at $52.91 after UBS analyst Eric Sheridan raised his rating on the social-media company to buy from neutral. Sheridan also lifted his price target on the stock to $65 a share from $50. Sheridan cited improvements in the outlook for digital advertising among the reasons for his upgrade.

Palo Alto Networks Inc. (PANW) shares rose 10.6% to close at $96.75 after the security-technology company reported upbeat quarterly results late Tuesday.

Gains also came from Microsoft Corp. (MSFT), Yahoo Inc. (YHOO) and Google Inc. (GOOGL).

EBay Inc. (EBAY) fell by 3% to $51.10. Piper Jaffray analyst Gene Munster cut his rating on eBay to neutral from outperform and lowered his price target on the stock to $55 a share from $63 on the grounds that Apple Pay could prove a disruption to the mobile-payments market.

The Nasdaq Composite Index (RIXF) rose 34 points to 4,586 while the Philadelphia Semiconductor Index (SOX) eked out a small gain.

Subscribe to WSJ: http://online.wsj.com?mod=djnwires

eBay (NASDAQ:EBAY)
Historical Stock Chart
From Feb 2024 to Mar 2024 Click Here for more eBay Charts.
eBay (NASDAQ:EBAY)
Historical Stock Chart
From Mar 2023 to Mar 2024 Click Here for more eBay Charts.