Championship side Millwall have secured the signing of the 19-year-old who will see out the season with Mark McGhee's side.
The Sports' chairman John Bonar said it was a deal that made sense for all involved.
“It suits all parties, Bonar told the club's website. "Harry will train at Millwall during the week, but will be back at the Lane for Borough’s Thursday night training sessions and available for selection by Mark McGhee for the Saturday.
“We are delighted for Harry, who came through our youth ranks and was frankly always destined for a level of football above National South.
"This represents very good business for all parties – but just as importantly, we are doing the right thing for Harry Ransom in human terms and we will be proud to follow his future progress in the game.
"I know that all supporters will join me in wishing Harry well.”