That's a really helpful explanation from Answer 1... my error seems to include:
https://www.example.com/index.html
https://example.com/index.html
but there is only one file index.html to have a canonical tag...
If I add to index.html, why does the console keep showing the 4 examples above? In my head it should just display all 4 as https://www.example.com/ and never see the others... But doesn't seem to be the case...