SNC-Lavalin Group Inc. has signed a deal to sell the bulk of its stake in Ontario’s 407 toll highway operator for $3.25 billion, some of which will go toward a loan from Quebec’s pension fund.

The OMERS pension plan will buy a 10.01 per cent stake in 407 International Inc., reducing SNC-Lavalin’s interest to 6.76 per cent, according to an agreement announced Friday.

For more than six months, SNC-Lavalin has been mulling a partial sale to help pay down its loan from the Caisse, Quebec’s pension fund operator. The two-year-old loan stipulates that the company must keep its headquarters in Montreal until 2024, when the balance would be paid off.

A spokesman for the Caisse — by far the largest SNC-Lavalin shareholder at 20 per cent — said the sale does not alter that condition.

SNC-Lavalin had previously paid off $500 million of the $1.5-billion loan, and plans to use the proceeds from the 407 deal to pay down another $600 million upon closing, according to the company.

“This is a truly unique and exceptional asset that we believe has been undervalued by the market for many years,” SNC chief executive Neil Bruce said in a statement.

“Through this transaction, we are able to benefit from crystallizing some of this value, while retaining an interest in a successful Canadian infrastructure asset that we are proud to have helped build.”

Analyst Yuri Lynk of Canaccord Genuity said in a research note that the sale has the effect of “immediately cleaning up” SNC’s balance sheet.

OMERS will pay $3 billion to SNC on the closing of the deal and an additional $250 million over 10 years, conditional on certain financial targets related to the performance of the toll highway.

The OMERS agreement with SNC is subject to certain rights of 407’s other shareholders, including rights-of-first refusal.

The other owners of the toll highway include a subsidiary of Ferrovial S.A., with a 43.23 per cent stake, and the Canada Pension Plan Investment Board with 40 per cent.

The deal is expected to close within two months.

Analysts say the transaction will yield net proceeds of $2.8 billion for SNC-Lavalin, assuming a tax rate of 13 per cent. The deal values the company’s total stake at about $27 per share, below the consensus of $28, according to analyst Benoit Poirier of Desjardins Securities.

He estimates the firm will put between $1.2 billion and $1.4 billion toward share buybacks over the long term.

“Bottom line, while the valuation for SNC’s stake in Highway 407 is below expectations, we believe the net proceeds should help SNC to deleverage and benefit from the stock’s current valuation,” Poirier said in a note to investors.

The company’s shares have hovered near 10-year lows of around $34 since Feb. 11, when it slashed its profit forecast for 2018 by more than 40 per cent and halted all bidding on future mining projects.

That reduced guidance came two weeks after it halved its forecast from November amid a diplomatic feud between Canada and Saudi Arabia — a key source of oil and gas revenue — and delays on its project with Codelco, Chile’s state-owned copper mining company, which has since cancelled the contract.

Friday’s deal comes as the SNC-Lavalin affair in Ottawa continues to simmer following accusations that top government officials pressured former attorney general Jody Wilson-Raybould to veto federal prosecutors’ move to prosecute the company on corruption charges instead of negotiating a remediation agreement.