Fairytale is an overused word in football, but how else do you describe the moment when a striker who has spent most of his professional life in the lower divisions comes off the bench – for his debut in an England-Scotland game at Wembley – and scores the winning goal with his first touch?

Rickie Lambert, at 31, certainly makes an unlikely hero – but a hero, all the same, after a goal that had therapeutic qualities for Roy Hodgson's team. A lot of people probably imagined he would be another one-cap wonder to file with Jay Bothroyd, Kevin Davies and David Nugent. Others barely concealed their disdain. Yet his impact here was so great Hodgson all but guaranteed him a place in the squad for the World Cup qualifiers against Moldova and Ukraine next month.

It was a goal of dreamlike quality from the Southampton striker, peeling away from his marker, the old-fashioned leap and, finally, the arching, powerful header. Lambert had not even been on the pitch three minutes but his introduction completely changed the emphasis of the evening from England's perspective.

Hodgson should be grateful for that because, at times, his team had threatened to make this a chastening experience. They were behind twice against willing but limited opponents and once again, there was hard evidence that the manager badly needs a reliable centre-half partnership. They could conceivably have lost because of those shortcomings. They also have a goalkeeper, Joe Hart, who can sometimes be a danger to his own team.

Yet the mood softens when there is something as exhilarating as the Lambert story, rejected as a teenager at Liverpool and supplementing his income at one stage by working at a beetroot processing plant on the eccentric career path that has taken him from Blackpool to Macclesfield, Stockport, Rochdale, Bristol Rovers and Southampton – and now his own chapter in the history of the England-Scotland rivalry.

Lambert, a replacement for Wayne Rooney midway through the second half, also struck a post in the final exchanges and was loudly serenaded by the Wembley crowd before the end. He should probably brace himself for some Lambert-mania over the coming days, but what he did here should not fully disguise the team's deficiencies. His goal was wonderful but, overall, the bottom line is this was another stodgy England performance.

They were behind twice, first in the 11th minute when James Morrison scored a goal that was a personal calamity for Hart, and then four minutes into the second half when Kenny Miller eluded Gary Cahill to score with a splendid left-foot drive. England responded with goals of their own from Theo Walcott and Danny Welbeck and, on the balance of play, deserved the victory. Yet there were long spells when they threatened to make a pig's ear of it. Defensively, Hodgson admitted, there were "a few holes in our game".

To put it into context, Scotland's starting XI featured seven English-based players but only one from a team that finished in the top half of the Premier League last season. Their substitutes included two players from League One, and the 33-year-old Miller earns his crust these days with Vancouver Whitecaps. Whatever the emotions and history surrounding this fixture, however well Scotland played, England should have made this a less harrowing victory.

Hart, for one, will not remember the night for Lambert's heroics. Morrison, not closed down quickly enough, struck his shot well but England's No1 will be aghast at the way it struck his gloves then skidded off his knees and into the net. It was the sort of mistake that would have been almost unthinkable a couple of seasons ago, and another reminder he might not be the goalkeeper that people thought he was. Not yet, anyway.

Steve Gerrard, unusually, had a below-par night, too, even if it was a lovely delivery to set up Welbeck to make it 2-2 with a glancing header. Jack Wilshere showed some nice touches in his 45 minutes. Tom Cleverley had one of his better games, the highlight being a beautifully weighted pass to send Walcott away for his goal, and Rooney probably did as well as might have been anticipated given this was his first start in a competitive match since April.

Yet the bottom line is that if England defend like this in Kiev they will almost certainly lose. Hart has now kept only three clean sheets – against San Marino, twice, and Moldova – in his previous 11 England games.

At least Hodgson is willing to veer away from the 4-4-2 system that prompted Gary Lineker's observation about "a step back to the dark ages" after the draw against Republic of Ireland. They had begun brightly but the opening goal was such a blow to their confidence it almost came as a surprise when Walcott, running through the inside-right channel, beat the offside trap and, checking back on to his left foot, turned a low shot beyond Allan McGregor in the Scotland goal.

The visitors were being pinned back by the end of the first half. Yet Gordon Strachan's side played with great conviction and always had a chance of springing a surprise when their opponents were so susceptible at the back. Cahill was beaten far too easily for Miller's goal, although the striker deserves the credit for the way he controlled Alan Hutton's right-wing delivery, with his back to goal, feigned to his left then went the other way and pinged a splendid left-foot shot into Hart's bottom right-hand corner.

England, driven forward by the substitute Frank Lampard, responded within four minutes, Welbeck reading the trajectory of Gerrard's free-kick to guide his header past McGregor. The game then became a story of England pressure, the occasional Scottish breakaway and a flurry of substitutions from both teams. But then the moment for which the game will be remembered. The run, the movement, the timing of the leap to meet the corner from Leighton Baines – it was all perfect.

Lambert set off on a victory run, pursued by his team-mates, and the new season had a fairytale worthy of the description.