There are lots of things that can affect school performance.
DH and I are both very academically success (not in other ways) and have two DS. Our DS7 is very studious and academically talented, which was apparent incredibly early, but he's autistic and somewhat lopsided towards technical subjects.
Our DS4 had the nickname 'ordinary L' for a long while because he was super cheery, uber friendly and... utterly unexceptional. He's very likeable, but it was impossible to teach him anything and, personality wise, he's a bit of a fruit loop.
It turns out that DS4 is also autistic, but also hypermobile and has possible ADHD. He's sufficiently smart that it shows up on a neurodevelopmental assessments, possibly even as smart as his brother, but you just can't tell because - unlike DS7 - he's not a nerdy kid. He just wants to hang with friends and all of his brainpower goes on that. Due to the ADHD-y and hypermobile elements, he struggles to hold a pencil and has the attention span of a cocaine-snorting goldfish.
It might read like I'm disappointed in DS4, but I'm totally not. They're just different kids. It's unclear which of the brothers will do better in grown-up life because social skills are as least as important as academic achievement. I always say that, if DS4 and DS7 ever set up a company together, DS7 would be the chief technical/operations officer, and DS4 would be the investor-charming CEO. One of them is serious and swotty, and the other is a complete charmer with a thousand-watt grin.