Piri Weepu, Williams' teammate in Auckland and another battling to regain his World Cup form, has also been retained, with Hansen revealing Weepu has been given an ultimatum - understood to be reaching a required weight _ or face non-selection.
"We always felt that to win test matches we're going to need experience on the park and history has shown us that if you don't have that you're going to be struggling so that was a big part of it,'' Hansen said when explaining his selections.
"Form was another criteria, obviously. We felt also that the wider training group would give us an opportunity to maybe bring a couple of younger guys along and have a look at them and see how they're going.
"Ali is a bit of an enigma isn't he? He has had a history of not playing well in Super Rugby before, but he's played 73 tests and I can't think of too many where he hasn't played outstandingly well. If we don't select him then we end up with very light experience across the middle row. Sam Whitelock would immediately become the most experienced with 25 tests. I'm confident that we can get him [Williams] into our environment and do what we've done in the past, get him to play well, get him to unclutter himself and do the job for the All Blacks. So we're backing ourselves to do that. He scrums well and we've lost a great scrummager in Brad [Thorn] so we're confident he'll do the job we need him to do.
"Obviously Piri has one or two question marks around how he's been playing and we've made it pretty clear what our expectations are of him and he's got to meet those expectations by the end of the last camp otherwise he won't be considered for selection.''
The two three-day training camps - in Auckland starting on Sunday and in Wellington a week later - allow Hansen and his fellow coaches Mike Cron, Ian Foster and Aussie McLean to keep tabs on the All Blacks in what will be a balancing act before the first test in Auckland on June 9.
This is the first time the mid-year tests have come in the middle of a Super Rugby competition. Hansen said the majority of the work would be on game plans and re-setting goals following the World Cup success.
A final 30-man squad will be named on June 3 and there are likely to be additions given the injuries to Richard Kahui and Keven Mealamu. Chiefs' centre Kahui would have been one of the wings against Ireland but dislocated a shoulder in his side's loss to the Reds in Brisbane last night, with Blues' hooker Mealamu is troubled by a niggling calf problem.
Crusader Corey Flynn or Chief Hika Elliot, who missed out on the training squad, are likely replacements.
Kahui's injury could offer a reprieve for Zac Guildford or Hosea Gear, although Hansen sounded extremely positive about 21-year-old Hurricanes' wing Julian Savea, a shining light for the World Championship-winning New Zealand Under-20 team in Argentina in 2010.
"He adds something a little different. He's a big guy with a lot of pace and scores lots of tries, so on form we felt he was the one we had to pick.''
Hansen said 20-year-old Cane could be the man to replace Richie McCaw at openside flanker.
"We're hoping so, hence why he's in the squad. He's been a player who we've had our eye on for quite some time and is an extraordinary young talent. Whether he can make the step up or not we'll have to wait and see. But we need to begin that process so it gives us an opportunity - one, to have a replacement and two, to have someone who will allow us to look after Richie over the next one to four years.''
Hansen said he was happy with Dan Carter's rehabilitation from his groin injury, revealing the player saw his surgeon in Melbourne when the Crusaders were in the city to play the Rebels recently.
"It's a pretty major operation that he's had and we're grateful to the Crusaders for looking after him.''