The topped shot is a very common mistake amongst many amateur golfers, especially those new to the game. I’ve seen all too many (so called) pros try to fix their students with all the wrong answers, trying to make it this hugely complicated issue to fix the problem, when the answer is really super simple stupid. The answer (and this has worked each and every time with countless students I’ve taught who top the ball) is to hit the ground solid every time you hit the ball off the ground by swinging down into the ball, hitting the ball first and then making a mean divot. When you top the ball, the club head is simply too high above the ball (not grounded) and you hit the ball on the extreme bottom of the face, like a thin shot but just more exaggerated. Sometimes if you’re standing too straight up and down (with bad posture) and not enough bend from the waist, it can be hard to get down into the ball.
So, bend more from the waist only, not the knees (if you’re doing that) to help yourself to get down into the ball and ground the club through impact each and every time you’re hitting the ball off the ground.