The mortgage loan origination system developer Ellie Mae is going private, agreeing to be acquired by the private equity firm Thoma Bravo in an all-cash transaction valued at $3.7 billion.

Current shareholders will receive $99 per share, a 47% premium to the 30-day average closing price as of Feb. 1. The transaction is expected to close in the second or third quarter.

Ellie Mae’s stock opened at $99.15 per share on Feb. 12, after closing the previous night at $81.92. The last time Ellie Mae traded over the acquisition price was on Sept. 18, 2018. It hit its 52-week low on Dec. 24, 2018, when the stock traded at $58.49 per share.

Ellie Mae is scheduled to announce its fourth-quarter earnings after the market closes on Feb. 14.

“Since the founding of Ellie Mae more than 20 years ago, our mission has been simple — to automate everything automatable for the residential mortgage industry,” Ellie Mae President and CEO Jonathan Corr said in a press release.

“As we enter this next phase of our digital mortgage journey, we are thrilled to provide immediate value to our shareholders,” Corr said. “With the investment and support from Thoma Bravo, we will remain committed to our customers’ success, innovation and growth of the Encompass Digital Lending Platform while maintaining our position as a best place to work.”

Among Thoma Bravo’s current investments in mortgage-related companies are MerdianLink, whose technology includes the LendingQB loan origination system; Kofax, which offers document capture software; and Hyland Software, which does electronic document management technology.

“Ellie Mae is leading the digital transformation of the residential mortgage industry and we look forward to building on the company’s successes and to our partnership through this next chapter of growth,” Holden Spaht, a managing partner at Thoma Bravo, said in the press release.

The agreement calls for a 35-day go-shop period.

JPMorgan Securities was the financial adviser to Ellie Mae and Cooley was its legal adviser. Jefferies LLC was Thoma Bravo’s financial adviser, and Jefferies Finance is providing the financing for the deal. Kirkland & Ellis served as legal adviser to Thoma Bravo.