Two teenagers have been detained in a young offender institution after they hit a boy with a bat and stabbed him in the chest.
The 17-year-old boy was attacked in Colchester, Essex, on 20 January.
Ben Goodspeed, 19, of Colchester, and Tate Heeney, 18, from Great Horkesley, pleaded guilty to wounding with intent.
They got seven and six years' detention respectively at Ipswich Crown Court for what police called a "brutal... senseless and violent" attack.
Essex Police said the victim suffered life-threatening injuries to his chest, back and arm.
The force said Goodspeed, of Monkwick Avenue, and Tate Heeney, of The Crescent, had chased him in Osborne Street.
He fell to the ground and they kicked him, hit him in the head with a short bat and then stabbed him in the chest with such force that the knife pierced his lung and went through his back, police said.
Det Con Danielle Markoutsis, the investigating officer, said: "The victim was extremely fortunate to have survived and it has left a lasting emotional and physical impact, which he continues to face on a daily basis.
"Hopefully knowing Goodspeed and Heeney have been taken off the streets for some time will give him and his family some comfort."