Simon Quin, 28, was sentenced to five years in prison after he and an accomplice lit a plastic bottle containing petrol and hurled it at a front window after the rapist was convicted of carrying out a sex attack on her.
The incendiary device caused damage to the house and garden at the property in Gorebridge, in Midlothian, where the 23-year-old woman was staying with her three-year-old son.
Quin was an acquaintance of Shane Ramsay, 22, who was jailed for seven years for attacks on two women last year, including the target of the fire bombing.
Quin, of Temple, in Midlothian, had earlier denied culpably and recklessly igniting the bottle and throwing it at the house to the danger of those within while acting with another, but was found guilty after an earlier trial.
A judge told him at the High Court in Edinburgh that his criminal act was “a particularly cowardly and despicable one”.
Lord Arthurson said: “It is clear to me the only appropriate disposal in your case requires to be a substantial custodial one.”
The judge said he took into account Quin’s stable family circumstances and that he was assessed as posing a minimal re-offending risk.
The woman told his earlier trial: “It happened so fast. As soon as I saw it coming I screamed ‘fire’. It woke everyone in the house. I saw fire all over the window.”
She said she ran upstairs to where her sister and partner were and to make sure her son was alright as he was in the room above.
She was able to escape uninjured with the child and other family members following the incident on June 11 last year. Quin’s DNA was found on a cigarette butt near the scene.
Defence counsel Ronnie Renucci QC said that Quin was realistic and realised that custody was inevitable following his conviction.
But he said prison would be particularly difficult for him as it was “a completely foreign environment” for him.
Mr Renucci said following his earlier remand Quin had already found prison “a salutary experience and a harrowing one”.
He said that shortly after he was taken to jail he was assaulted in Addiewell prison, in West Lothian, and ended up in hospital. He was later moved to Edinburgh’s Saughton prison for his own safety.
Join our Facebook group Our Edinburgh to share images and news from and around the Capital