By Liana B. Baker

(Reuters) - LogMeIn Inc <LGMO.O> and a unit of Citrix Systems Inc <CTXS.O> that makes software products such as GoToMeeting said on Tuesday they are merging in an all-stock deal to create a $1.8 billion company focused on technology applications for the workplace.

LogMeIn shareholders cheered the deal, sending shares up more than 20 percent in after-hours trading. Citrix shares were down 1.94 percent after closing at $89.33 in regular trade.

The transaction, which the companies said should close by the first quarter of next year, replaces an earlier plan announced by Citrix to spin off the GoTo business. Citrix had been targeted by activist hedge fund Elliott Management, which has pushed the company to sell various units to create shareholder value. Elliott's senior portfolio manager Jesse Cohn sits on Citrix's board.

The deal is structured as a Reverse Morris Trust, which is a tax-free deal in which one company merges with a spun-off unit. Citrix will create a subsidiary to hold the GoTo business, which it will then merge with LogMeIn. Shareholders will receive about 27.6 million LogMeIn shares.

Citrix's GoTo business, which makes video conferencing software, is larger than LogMeIn, which had a market value of $1.77 billion on Tuesday. LogMeIn helps employees log into their company's computers systems from outside the office; it went public in 2009.

Citrix shareholders will end up owning 50.1 percent of the combined company while LogMeIn shareholders will own 49.9 percent. LogMeIn's chief executive, Bill Wagner, will run the company and its board will be comprised of five directors from LogMeIn and four appointed by Citrix. Citrix will also contribute $25 million in cash to the new company, which will have revenue of about $1 billion.

Reverse Morris Trust transactions have become an elegant solution for legacy technology companies looking to divest assets while saving on taxes. Hewlett-Packard Enterprise Co <HPE.N> announced one in May <CSC.N>, with its call center and services unit merged with Computer Sciences Corp <CSC.N> to create a $9 billion company.

While Citrix has now found a home for its GoTo products, it may not be done with M&A. Elliott has previously called on Citrix to explore the sale of NetScaler, a technology business that helps speed up web-based applications.

RBC Capital Markets <RY.TO> advised LogMeIn, and Qatalyst Partners and Goldman Sachs <GS.N> advised Citrix. Legal advisers were Latham & Watkins LLP for LogMeIn and Goodwin Procter LLP and Skadden, Arps, Slate, Meagher & Flom for Citrix.

(Reporting by Liana B. Baker; Editing by Leslie Adler)