The nationality of the title character in Charlie and the Chocolate Factory is not, as far as I know, ever stated explicitly; however, the denominations of money that he uses seems to place him in the UK:
Under cover of the bedclothes, the old man opened the purse and tipped it upside down. Out fell a single silver sixpence. 'It's my secret hoard,' he whispered.
Then one afternoon, walking back home with the icy wind in his face (and incidentally feeling hungrier than he had ever felt before), his eye was caught suddenly by something silvery lying in the gutter, in the snow. Charlie stepped off the kerb and bent down to examine it. Part of it was buried under the snow, but he saw at once what it was.
It was a fifty-pence piece!
Note that Charlie and the Chocolate Factory was published in 1971, the same year that the UK moved over to a decimal currency system. Fifty pence pieces had been introduced in 1969, in anticipation of the change, explaining why they were in circulation at the same time as silver sixpences. I believe that this gives further evidence that the story is set in Britain.
Charlie and the Great Glass Elevator, the sequel, was published a year later (1972) in the US and two years later (1973) in the UK. Dahl appears to have decided to appeal to the American audience, because Charlie and his whole family become American:
At that precise moment, Grandma Josephine poked her head out from under the sheets and peered over the edge of the bed. Through the glass floor she saw the entire continent of North America nearly two hundred miles below and looking no bigger than a bar of chocolate.
Of course, if they'd blasted off from Britain, she might still have seen that continent from space. But later on, when Grandma Georgina becomes 358 years old, she seems to have lived most of her life in America:
The tiny sunken black eyes glimmered faintly and a sort of smile touched the corners of the almost invisible little slit of a mouth. ‘There was a ship,’ she said. ‘I can remember a ship … I couldn’t ever forget that ship …’
‘THE MAYFLOWER!’ cried Charlie.
Her other memories from her life have a distinctly American flavour:
Every second now she was growing slightly less and less shrivelled, becoming more and more lively. It was a marvellous thing to watch. ‘Gettysburg!’ she cried. ‘General Lee is on the run!’ And a few seconds later she let out a great wail of anguish and said, ‘He’s dead, he’s dead, he’s dead!’ ‘Who’s dead?’ said Mr Bucket, craning forward. ‘Lincoln!’ she wailed. ‘There goes the train …’
As well as the following -- which is, not surprisingly, not present in the UK edition of the books:
We've beaten them! Yorktown's Surrendered! We've kicked them out, those dirty British!
My question is this: was there ever any explanation given, either by Dahl or by the publishers, for why Charlie changes nationality from one book to the next? Was it ever commented on at all?