Two tries from Mark Bennett on top of scores from John Hardie, Tommy Seymour and Finn Russell ensured the Scots avoided a potential banana skin as they also claimed a valuable bonus point.
Japan arrived at Kingsholm full of confidence after their shock win over South Africa in Brighton but it was Scotland who got the start they were after as skipper Greig Laidlaw kicked an early penalty.
But just seconds after he put over his second kick, Japan hit back. Ayumu Goromaru's kick into the corner teed up a line-out and Mafi went over the line from the line-out drive for a try converted by Goromaru.
Laidlaw hit back with two penalties as Japanese discipline began to fray at the edges and Matsushima was sin binned for cynically playing the ball on the ground just as Scotland looked to launch a counter attack.
The Scots finally got themselves on the front foot in the final exchange before the break but just as Seymour looked set to dive over in the corner, Goromaru produced a stunning last-ditch tackle to maintain the five-point deficit.
Japan were still hungry for another upset and it took a last-gasp stop by Mark Bennett to prevent Mafi scoring again after he scooped up Ross Ford's wild line-out throw.
It proved to be the number eight's last involvement though as he was stretchered off with a neck injury. Goromaru, though, eased his side's pain as he rattled over a penalty.
But Scotland extended their lead as they borrowed some of Japan's attacking guile. Matt Scott's beautiful offload allowed Sean Lamont to break ground and while their opponents were able to halt the Scots before Stuart Hogg could finish off, they were helpless as Hardie waited patiently for his chance in the corner.
Laidlaw missed the conversion but there was a let off again when Goromaru struck a post from his next effort.
But having put so much into their first two games, Japan were always likely to tire and Scotland took advantage. First Hogg slalomed 40 yards forward and when the gaps continued to appear in the Blossoms' defence, Bennett sped through to score under the posts, with Laidlaw converting.
Scotland could finally breathe easy with 17 minutes left when Seymour intercepted a Yu Tamura pass before running 70 yards up field to put the game beyond Jones' men. Again Laidlaw put over the extras.
By now the Japanese were running on empty and Bennett scored again to hand his side the all-important bonus point as he ghosted in off the back of ruck. Laidlaw added another successful conversion.
Russell then got in on the act as he collected a short pass from Laidlaw after a five-yard scrum and danced his way over for the firth touchdown. Laidlaw again converted.