Should my site use www or non-www?
Pick one and send everything else to it. Which one you choose genuinely does not matter — what matters is that only one of them serves pages, because a site reachable at several addresses is treated as several sites competing with each other.
What it actually is
To a person, the bare domain and the www version are obviously the same place. To a machine they are two different hostnames, and unless you say otherwise the safe assumption is that they are two different sites that happen to look identical. Everything your site has earned — links, authority, history — attaches to a specific address rather than to the brand behind it.
Why it matters
The damage is quiet and cumulative. Every link anyone makes to the wrong variant builds up credit at an address you are not trying to rank, and the two versions end up competing for the same searches while each holds part of the total. You can be doing everything else right and still be beaten by a weaker competitor who simply consolidated.
What good looks like
One hostname serves your site and every other variant permanently redirects to it, preserving the rest of the address as it goes. Internal links, the sitemap and any canonical declarations all agree on that same choice, so there is never a page that says one thing while the server says another.
Being honest about it
The choice between www and bare is aesthetic, not technical, and anyone who tells you one ranks better is selling something. There are mild practical arguments each way around cookies and DNS flexibility, and for most sites neither will ever matter. Consolidating is what matters, and having consolidated, changing your mind later is genuinely disruptive — so this is worth settling once.
Where most sites go wrong
The most common failure is a site that redirects correctly at the front door and not anywhere else, so the homepage consolidates while every deep page stays split. The second is disagreement between layers: the server prefers one variant, the pages declare the other, and the sitemap lists a third. Each component is individually defensible and the combination tells machines nothing they can act on.