Miller, 29, was 4-4 with a 4.95 ERA last year with Boston. He underwent surgery on his right labrum in September, but expects to return in May.
The Mariners, Pirates, Astros, Phillies and Red Sox had also expressed an interest in Miller, who is 62-43 in seven seasons with Houston and Boston.
"We had a handful of teams interested in Wade, but the Cubs were very aggressive the last couple of days, and that's where he decided he wanted to pitch," said Bob Garber, Miller's agent.
Miller, who made $1.5 million last year with Boston, can earn an additional $1 million in incentives.
Jerry Crasnick covers baseball for ESPN Insider.