After visiting a Kent army camp where Ukrainian soldiers are being trained, Mr Stoltenberg said the UK was playing a “key role” in “leading our efforts” to help the country against Russian aggression.
It is also “encouraging” to see Ukraine making territorial gains, he said, as Moscow announced that it was withdrawing from the southern city of Kherson and nearby areas.
“We have seen the announcement but we will of course wait and see what actually happens,” Mr Stoltenberg said.
“What we do know is that Russia has been pushed back, first from the north around Kyiv, then in the east around Kharkiv, and then actually we see slowly how the Ukrainians are able to push back the Russian forces also in the south around Kherson.
“So it is encouraging to see how the brave Ukrainian forces are able to liberate more Ukrainian territory.”
Ukraine war latest - in pictures
Mr Sunak earlier welcomed Mr Stoltenberg to Downing Street, saying there was “lots for us to talk about”.
“You’ll know that the Nato alliance is a cornerstone of the UK’s security," the Prime Minister said at the start of the meeting.
"We’re proud to be the second-largest contributor and we remain extremely committed to the alliance.
“I also know under your leadership that Nato will continue to evolve to face the new threats that we’re all seeing, and [we will] of course work with you and other allies to support Ukraine against Russian aggression.”
After the talks, Mr Stoltenberg said it had been a “good meeting”.
He said he used the opportunity to praise Mr Sunak for “the strong support that the United Kingdom provides to Ukraine”.
Mr Stoltenberg said Russian President Vladimir Putin made “several huge mistakes” when he invaded, including underestimating Nato’s ability to support Ukraine.
Antonov AN-225 destroyed by Russia in Ukraine - in pictures
“What we see when you look at the opinion polls, the political messages from different Nato-allied countries, is that we are ready to continue to provide support for as long as it takes,” he said.
Mr Stoltenberg said there were “always some voices that have a different opinion”, but the “clear message” from most is that “we will continue to support Ukraine”.
Downing Street said the pair agreed on the importance of the alliance “continuing to adapt to face new threats”.
Mr Sunak also outlined plans to update the UK’s Integrated Review on defence and security, a government spokeswoman said.
Ukraine capital Kyiv hit by kamikaze drones - in pictures
There has been some uncertainty over whether Mr Sunak would stick by his predecessor Liz Truss’s pledge to boost the investment as a proportion of GDP to 3 per cent by the end of the decade – a more ambitious target than Nato’s minimum of 2 per cent.
“The United Kingdom has led by example over many years when it comes to … defence spending, spending more than 2 per cent of GDP on defence; the United Kingdom has done that and now more and more allies are following example of the United Kingdom,” Mr Stoltenberg said.
“But of course, in a more dangerous world we need to invest more in our defence, and I am absolutely confident that the United Kingdom will continue to lead by example on defence spending.”