Canadian National Railway has sold a rail corridor between downtown Toronto and Pickering, Ont., to Ontario's regional transportation agency.

Metrolinx, which operates GO Transit rail and bus services, is paying $299 million for the Kingston Subdivision rail line.

The rail line is composed of the two and three-track rail corridor east of Union Station to where the line connects with GO Transit's right-of-way near Whites Road in Pickering, the community just east of Toronto.

Metrolinx president and chief executive Bruce McCuaig said the provincial agency has gained full ownership of an important segment of GO Transit's eastern commuter rail corridor.

"Owning this rail corridor section better positions GO to improve service, better control operations and plan future service growth," he said

Metrolinx now owns 61 per cent of the rail corridors on which GO Transit operates.

CN chief executive Claude Mongeau said the country's largest railway (TSX:CNR) is pleased to sell the rail link while protecting its operating rights over the line, to ensure continued service to its freight customers.

"CN has a strong partnership with Metrolinx and we will continue to support commuter rail as a sustainable mode of transport in the Greater Toronto Area."

Metrolinx is the Ontario government's regional transportation agency for the Greater Toronto and Hamilton Area. Its GO Transit system carried more than 57 million passengers a year on its network of trains and buses.