Ipswich defender Damien Delaney has extended his stay at Portman Road until 2013, with the option of a further year until 2014.
The 29-year-old, who arrived at Portman Road 21 months ago, has featured 32 times this season.
The deal brings to an end the ongoing saga over the Republic of Ireland international's future.
"I'm obviously delighted that everything is done and dusted now," the centre-half told the club website.
It is understood the deal could run to a third year if Delaney plays an undisclosed number of games.
"I'm looking forward to spending at least two more years here and helping the club reach the Premier League," the former Hull player added.
"I came here to win promotion and that's the aim. I believe we can do it and I wouldn't have signed a new deal unless I felt that.
"There is a lot of optimism about the place and the results have shown that recently.
"There are too many positives, too much optimism to walk away from Ipswich Town. I tend to follow my gut instinct and everything was telling me to stay here and be part of a club that is moving forward."
Ipswich supporters will hope Delaney's deal will open the floodgate on new contracts for other senior players at the club.
"We've agreed a deal with Gareth, we're just waiting for him to come in and sign it," boss Paul Jewell told BBC Radio Suffolk.
"I see there's a bit of speculation about a couple of clubs being in for him, so we'll try to get to the bottom of that.
"But we'd like Gareth to sign, we've given him what he wants."