Alfred Sosa will have to register with local law enforcement, according to Fresno County Superior Court Judge Stephanie Negin.
Surveillance video from February 2024 shows Sosa approaching a dumpster, setting debris on fire, and then walking away. Within moments, the Peerless Building sustained thousands of dollars in damage.
Days later, Sosa then struck Valley Foods, starting a similar fire there.
Sosa has since pleaded no contest to one count of arson.
"Mr. Sosa is currently youthful," his attorney said in court on Friday. "His substance abuse issues, unfortunately, contributed to the conduct in this case."
RELATED: Fresno business feeling relieved after investigators arrest arson suspect
The attorney asked for probation, but the judge denied it.
"You were on probation - juvenile probation -- at the time this offense occurred," Judge Negin said. "This was a serious offense."
Judge Negin sentenced Sosa to two years. With credit for time served, he could be out within three months.
"It's hard not to be angry," Nader Assemi, the co-owner of the Peerless Building, told Action News in 2024.
On the phone Friday, Assemi characterized the fire as "frustrating," but said he is not worried about a repeat attack, describing the problems in downtown Fresno as ever-changing.
"You can't let this stuff get you down," Assemi said in 2024. "This is part of owning a business. They're minor setbacks, and you kind of take it in stride."
For news updates, follow Gabe Ferris on Facebook, Twitter and Instagram.