NEW YORK — In a surprise move, Microsoft said Mon- day that it is buying professional networking service site LinkedIn for about $26.2 billion. It is by far Microsoft’s largest acquisition — much larger than Skype, which the company bought for $8.5 billion in 2011.

LinkedIn, based in Mountain View, California, has more than 430 million members. Users can network with other professionals, upload their resumes, catch up on career advice and search for jobs on its site and apps.

Microsoft Corp. is paying $196 for each share of LinkedIn Corp., a 50 percent premium over the stock’s closing price of $131.08 on Friday. The deal is expected to close this year.

LinkedIn will remain an independently run unit of Microsoft. It will keep its name, and current CEO Jeff Weiner will stay on and report directly to Microsoft CEO Satya Nadella. Microsoft is based in Redmond, Washington.

For Microsoft, the deal means access to LinkedIn’s hundreds of millions of users and an opportunity to cement itself as the tech company for the world’s professionals, helping them find jobs, learn new skills and do their work.

“Together we can accelerate the growth of LinkedIn, as well as Microsoft Office 365 and Dynamics as we seek to empower every person and organization on the planet,” Nadella said in a statement. Office 365 is a subscription- based version of Microsoft’s traditional office-software suite; Dynamics is a software tool that helps companies track sales prospects and other “customer relationships.”

Analysts agreed. The deal “makes sense and helps round out the company’s business applications portfolio,” said Evercore analyst Kirk Materne.

LinkedIn’s business and share price have been on a roller coaster recently. In February, it gave a surprise forecast for slower growth that led to a big sell-off, wiping out nearly $11 billion in market value. The company said at the time that its adjusted earnings would be 55 cents a share on revenue of roughly $820 million. Its stock climbed higher after it reported better than expected results for the first quarter, though not enough to recover from the earlier plunge.

In an email to LinkedIn employees posted online , Weiner asked them to give themselves “some time to process the news.”

“You might feel a sense of excitement, fear, sadness, or some combination of all of those emotions. Every member of the exec team has experienced the same, but we’ve had months to process,” he wrote. “Regardless of the ups and downs, we’ve come out the other side knowing beyond a shadow of a doubt, this is the best thing for our company.”

LinkedIn shares soared 47 percent to $193.36 in morning trading Monday. Microsoft shares slipped 3.9 percent to $49.48.