Stokes fittingly took the final two wickets as England clinched a 22-run win in Chittagong on the final morning, having bailed out the tourists with both ball and bat as the Test unfolded.
It was arguably Stokes’s finest all-round display in an England shirt and that it came on a turning pitch not generally suited to his strengths was all the more satisfying for Bayliss.
The England head coach has been impressed with Stokes’s determination to improve his batting against spin and his form augurs well for England ahead of a testing schedule this winter, with five Tests in India to come following the conclusion of the Bangladesh tour later this week.
Bayliss said: “The potential of the guy, he could be right up there with some of the all-time best all-rounders. Only time will tell. Certainly the strides he’s made on the sub-continent playing spin has been top-class.
“It wasn’t all that long ago we were wondering how he might go on spin-friendly pitches, but he’s a guy that works extremely hard in the nets.
“I think it’s his defence to spin that he’s improved out of sight. We know that if he gets a bad ball he can hit anything over the fence but you’ve got to be there to get that loose ball.”
With another six Tests to play before Christmas, England have stressed the need to manage workloads and while that might mean resting key personnel, Bayliss was reluctant to include Stokes in that category.
The Australian said: “With him, we’ve got to watch what he does between the Tests to make sure he is available for all the matches. He allows us to play that extra spinner and the third pace bowler. He’s very important.”
The performance of Stokes, and others such as Jonny Bairstow and Moeen Ali with the bat, papered over some of the cracks in the line-up, most notably the top order.
In both innings, England were four down before the 100 was up as they cracked under the pressure of facing spin at both ends from the start, with Gary Ballance’s place seemingly vulnerable after a lean run following his recall to the side earlier this year.
Despite Ballance averaging only 22.77 in his last five Tests, Bayliss suggested England will stick with the same top six in the second Test in Dhaka on Friday, and any changes are likely to be in the bowling department.