Caleb Clarke celebrates a try with Sevu Reece. Photo / Photosport
All Blacks 38 Japan 31
The All Blacks have barely avoided yet more unwanted history, but on tonight's evidence Japan won't have to wait long for a breakthrough victory.
An inconsistent season for the All Blacks continued - and was captured in microcosm - as they battled to an uninspiring win over an inspired opposition in Tokyo.
The Brave Blossoms were a try away from a stunning upset in the final moments, after Brodie Retallick had been sent off for a dangerous cleanout with 15 minutes to play.
But Richie Mo'unga's penalty sealed the result after the All Blacks defence had done just enough to survive - having received a first-hand demonstration of defensive resilience throughout the match.
The Brave Blossoms, whose previous best result against the All Blacks was a 38-point loss the last time these sides met in 2018, impressed with and without the ball.
Considering their quality in all facets, Japan will now be hopeful of adding the All Blacks to a list of scalps that includes South Africa and Ireland.
Jamie Joseph's side also seriously tested France earlier in the year and were primed for this clash after a three-match series against Australia A.
The All Blacks, meanwhile, have been inactive since winning the Rugby Championship, the high point of a year that included historic home defeats by Ireland and Argentina.
Both their inactivity and vulnerability were clear throughout tonight's match. Any attacking continuity was evident only in patches, partly by design and partly due to their obdurate opposition.
Once prone to being overpowered up front, Japan tackled at a high level throughout. The All Blacks physicality did create a couple of tries, but by and large the hosts held their own at the collision.
Unable to regularly pierce through the Japanese defence, the All Blacks repeatedly opted to go over it, kicking high but not contesting often enough for the tactic to prove effective.
Ian Foster's side initially struggled with their opponents' line speed in defence, looking disjointed with the ball as they struggled to get out of their own half. That could have been anticipated given their layoff and a much-changed team; equally predictable was their individual quality eventually shining through.
The first sign of that was Samisoni Taukei'aho's offload for Retallick's opening try, the hooker having been elevated into the starting side after Dane Coles suffered an injury during the warmup.
And his teammates proceeded to follow Taukei'aho's lead, relying on quick hands to draw tacklers and stretch the Japanese defence. Roger Tuivasa-Sheck was an unsurprising standard-bearer in that respect, linking impressively with Mo'unga and Stephen Perofeta to set up Braydon Ennor's try.
Tuivasa-Sheck was again central to the third, with three pieces of brilliance completing a lineout move straight from the Joe Schmidt playbook, with Taukei'aho's's long throw collected and slipped inside by the starting debutant for Sevu Reece to finish in style.
But Japan were unbowed by the All Blacks sparking to life, subduing them with two tries to pull within 21-17 at the break. The first - part of Takuya Yamasawa's 16-point haul - involved a little luck but the second was nothing but skill, as the outstanding Dylan Riley producing a fine offload of his own for Yutaka Nagare to cross.
That try exemplified Tony Brown's influence, with Japan proving increasingly confident in possession. Handling errors let them down on occasion but their threat only enhanced as the match progressed.
Once again, Japan could have wilted after Caleb Clarke's power saw the All Blacks strike early in the second spell. But the home side did just the opposite, showing little fatigue from their defensive efforts to continue frustrating their opponents both at the set piece and in open play.
New Zealand-born lock Werner Dearns soon closed the margin with a spectacular piece of play, charging down Finlay Christie, collecting the ball and racing to the line.
Retallick's red then provided Japan an opening and Kazuki Himeno's 77th-minute try gave them one last shot, but the All Blacks defence saw the job done. Just.