Daniel Wayne Surette, 27, and Kyle David James Fredericks, 26, doused Lawrence with $10 worth of gas and set him on fire on Oct. 23, 2013, in a bus shelter in Berwick.
They were sentenced Tuesday in the Supreme Court of Nova Scotia in Kentville.
Justice Gregory Warner accepted the joint recommendation from the lawyers, ruling that Surette would not be eligible for parole for 20 years. Fredericks will be eligible to apply for parole in 18 years.
"It's hard to imagine a more horrible death," Warner said. "It's hard to imagine something so animalistic."
Surette also addressed the court, saying "I know what we done was severely f--ked up." He added that he hoped people could move on and find closure.
Fredericks did not address the courtroom.
The pair thought Lawrence may have been a police informant and made the decision together to set him on fire, according to an agreed statement of facts read out in court on Tuesday.
'Let's get the bum'
Surette and Fredericks each pleaded guilty to second-degree murder when they made a brief court appearance two months ago. The guilty pleas came just moments after they agreed to end the preliminary inquiry.
"There seems to have been this animus towards Mr. Lawrence that had been festering for a while. They viewed him as a bum, they viewed him as a possible rat or narc and that seems to have played some part in their eventual decision to do this horrific act," said Crown prosecutor James Fyfe at the time.
The agreed statement of facts described how the two men went to the gas station the night of Lawrence's death.
"It was while they were in the Foodland Parking lot (right where the bus shelter was) while on their way to the Needs store that Surette said something to the effect of, 'Let's get the bum' or "Let's burn the bum,'" said the statement.
"Fredericks was not certain what was said exactly, but he said that they both understood that they were going to set the homeless man on fire."
Second-degree murder carries an automatic life sentence, with no chance of parole for between 10 and 25 years. Parole eligibility for each man was decided on Tuesday.
The hearing also gave Lawrence's family and friends a chance to describe what his death has meant to them in victim impact statements.
'I did something bad to the homeless guy'
During their preliminary inquiry in February, the court heard testimony from Becky Surette, Daniel Surette's mother. She said everyone in Berwick knew Lawrence, but there was a rumour he was an undercover police officer.
She said her son and Fredericks sold drugs to buy party supplies, which included hard liquor, four dozen beer, cocaine, dilaudid, ecstasy and marijuana.
Surette testified her son arrived home the night Lawrence was killed and told her, "Mom, I did something bad to the homeless guy."
Police used security video from various local businesses to figure out the movements of Surette and Fredericks leading up to the killing.
It took six months for police to declare Lawrence's death a homicide, and Surette and Fredericks were not charged until April 2014.
The CBC's Angela MacIvor live tweeted the court proceedings.Suggest a correction