Lavery, 26, will be looking for a fourth successive promotion.
The Canadian-born striker, who began his career at Sheffield Wednesday, helped the Blades win promotion to the Championship in 2016/17.
"It doesn't do players any good to keep going out on loan," said Walsall manager Darrell Clarke. "But he's got a home now.
"I'm pleased to get Caolan in. He's another piece of the jigsaw. He's experienced and a hard worker, which fits the bill in terms of what I'm after from centre forwards.
"And he knows where the back of the net is."