Enroth was scheduled to become a restricted free agent before signing on Thursday.
Enroth had a 2.6 goals-against average and a shutout in going 4-4-2 in 12 games last season, his third in the NHL. Buffalo selected Enroth in the second round of the 2006 draft.
Overall, he has a 2.72 goals-against average, three shutouts and a 21-18-10 record in 53 career games.
He's coming off a solid spring, during which Enroth was chosen the World Ice Hockey championships top goalie in helping Sweden win the gold medal.
Enroth has the potential of taking over the No. 1 job in Buffalo with starter Ryan Miller entering the final year of his contract.