When you have content that is accessible under multiple URLs, or even on multiple websites, and you don't explicitly tell Google which URL is canonical, Google makes the choice for you. By using the
rel="canonical" link tag, you can tell Google which version should be prioritized in search results.
Doing canonicalization well improves your site's SEO, and doing canonicalization wrong can be catastrophic. Let's hope I did it right!
— Dries Buytaert