It's complex. I'm extremely unhappy with the way the Swedish gov handled this.
I see two main failures:
1. Not reacting quickly enough. Denmark and Norway reacted quickly and strongly back in early March 2020. At this critical point, Sweden's "CDC" dropped the ball in a monumental manner, and the government didn't pick it up.
2. Not protecting municipal elderly homes in a competent way, early on. This is where most deaths happened. Norway in particular handled this so much better.
And of course we should compare ourselves to e.g. Denmark/Norway/Finland.
I think the root cause of all this is that Sweden has not been involved in a war in a very long time, unlike our neighbors. We're pretty good when things are stable, but apparently awful when things are dynamic/shit is going down.
Of course I have very specific opinions on what "actually" went wrong and why, but that would be too detailed to be useful here and also way too partisan.