Holyrood has unanimously passed new legislation that will mean fewer children have to go to court to give evidence.

Community safety minister Ash Denham hailed the provisions in the Vulnerable Witnesses (Criminal Evidence) (Scotland) Bill as a "milestone" that will help protect youngsters.

It will ensure children who have to give evidence in more serious cases, that are dealt with by a jury, can pre-record their testimony.

This will then be shown to jurors, instead of youngsters having to go into the witness box.

Hundreds of children a year could benefit from the change, the Scottish Government said.

After the Bill was passed, Ms Denham said: "This is a milestone in Scotland's journey to protect children as they interact with the justice system, and a key part of our wider work to strengthen support for victims and witnesses.

"Children who have witnessed the most traumatic crimes must be able to start on the path to recovery at the earliest possible stage and these changes will allow that, improving the experiences of the most vulnerable child witnesses, as far fewer will have to give evidence in front of a jury.

"We are committed to ensuring these significant reforms are implemented in a considered, effective way and we have already provided the Scottish Courts and Tribunal Service with more than £2m to upgrade technology and create hearings suites that will support child and vulnerable witnesses to give their best evidence."

She also announced the charity Children 1st will receive more than £44,000 to ensure children and their families can help inform the Government's approach to justice.

Chief executive Mary Glasgow said: "By listening to children and young people's voices during the passage of the Vulnerable Witnesses Bill, the Scottish Government and Parliament have united around the vision of a justice system that gathers children's best evidence quickly and fairly while also supporting them to recover from their experiences and move forward with their lives."