How many musical keys are there? The internet seems to like the number 30 because there are 15 engraveable keys. And each has a major and a minor variant.
The engraveable keys are the ones you’re likely to see notated in sheet music. But it’s worth noting that each of these keys has at least two variations. The natural minor and the harmonic minor.
The other reason this is ultimately unanswerable is because at some point we have to start looking at the enharmonic keys. Those are notes that have two different names. The 30 keys already include a few like the G# or the Ab.
And on the keyboard those are both the same note. But let’s look more carefully at the key of G# because it also has an A# in it. And in the key of A#, oh boy, you’re gonna find an A#, B#, a C double sharp.
Take this to its logical conclusion and you start including double and triple sharp keys and it never ends. So personally when somebody tells me to practice something in every key, they mean 12. One for each of these ends.
So that’s what I do.