Andy Noble, 28, carried out the act of kindness because of the ‘cheer’ the crossing patrol guard called Elizabeth brings to those during her daily patrol.
Elizabeth works on Captain’s Road near Gracemount High School in Edinburgh.
She was left shocked but delighted when Andy surprised her with his gift last week.
In a post on his Facebook page, Andy said: “Elizabeth is that person who always waves and always smiles.
“Everyone that travels along Captains Road will know this lovely woman.
“I bumped into her on Saturday at Claire’s and she melted my heart. She attended the schools Children in Need charity night and took her beautiful wee daughter up on her bike.
“While inside some inconsiderate individual stole it. So I was waiting on her this morning to ask if the school had done anything to retrieve it and she replied no.
“I told her to shut her eyes while I nipped to the back of my van.
“Last night after my shift I went away and bought her a bike for her daughter. Poor woman had tears in her eyes.
“She’s been the lollipop lady for the area for a few years now and is such a lovely person. I’ve passed her for about a year and a half now but I stopped to talk to her properly at the weekend.
Andy works as a personal fitness instructor, waited until his shift was over and went straight to the nearest bike shop to buy a brand new bicycle complete with pink flower decoration.
Andy, from Bonnyrigg in Midlothian, posted a photograph of the delighted Elizabeth up on his Facebook page, an image which has since received more than 10,000 likes.
Stuart Scott said: “Noble by name, Noble by nature. This was a lovely gesture to a really lovely lady who never fails to give you a smile and a wave when you pass by.”
Another said: “I love her x she is an amazing woman.”
“How lovely, I know her and she’s the nicest person you could meet,” added Andrea Muir.
Andy, who says he has been left equally overwhelmed by the attention his post has received, says Elizabeth had been “left in tears” by the many kind messages people have been leaving for her.
He added: “I spoke to the headmaster of the school who has since said that her daughter’s bike has been found but it is all smashed up by whoever stole it.
“I’m just glad I was able to make the little girl and her mother happy. They seemed to have been having a wee bit of a tough time.”