All railway level crossings in Scotland are to get safety barriers, Network Rail have confirmed.
It follows the successful completion of a pilot scheme testing new mini barriers at a level crossing in Ardrossan in Ayrshire.
The first places to get them are all in the Highlands. They are Corpach, Brora, Kirkton and Dalchalm.
There are 23 open level crossings in Scotland, most of them in the Highlands.
Network Rail also said that a half-length barrier would be put in place at Halkirk in Caithness.
It was the scene of a crash between a car and a train that killed three elderly members of the same family in September 2009.
Network rail is to spend £4m on upgrading the crossings and expects to have completed the improvements by 2014.
The new barriers can be installed for about £100,000 a crossing, compared to an average of more than £500,000 under the old system.
David Simpson, Network Rail route managing director for Scotland, said: "The trial of this new system on single line railway at Ardrossan has been a fantastic success.
"We have developed and successfully tested an affordable, innovative system that will improve the safety of open level crossings."
Dave Thompson, SNP MSP for Skye, Lochaber and Badenoch, has been a vocal supporter of the new system.
He said: "I was delighted to see the successful completion of the new AOCL+B level crossing system at Ardrossan.
"I welcome the announcement that four Highland crossings will now be upgraded forthwith.
"These four barrier implementations on open Highland crossings are the initial first tranche of a roll-out to all the open crossings that remain in the Highlands."
He called the move a "major step forward" in road and rail safety.
Cabinet Secretary for Infrastructure and Capital Investment, Alex Neil, said: "Railway safety, including at level crossings, remains reserved to Westminster.
"However, to demonstrate our commitment, the Scottish government earlier this year announced an additional £10m fund to help facilitate the closure of level crossings and I will continue to liaise with Network Rail on these issues."