Carver was brought back to the club in January on a contract until the end of the season, but has impressed as Alan Pardew's right-hand man.
Having previously served as number two under Sir Bobby Robson at St. James' Park until September 2004, Carver knows Newcastle as well as anyone.
And the 46-year-old is delighted to have extended his stay, saying: "It is great to get this sorted.
"It was right for the manager to give me a short-term deal at the time, because I didn't know him and a lot of the players had changed too.
"But it's been a great month or so, and when he gave me the long-term deal I was delighted.
"I've been around the world over the last few years and need to settle down now, and where better than my home town club."
Pardew added: "John returned here in January on a short-term contract to allow us to work together and get to know each other.
"It has been without doubt a huge success. I've really enjoyed working with John and I am delighted he has signed a new deal to make this a long-term partnership."