There's no fixed number. It could be as few as one protagonist in a character-driven story, or it could be a whole ensemble in a story with multiple interwoven storylines. The key is that each character should serve a purpose and contribute meaningfully to the story's development.
It really depends on the type and scope of the story. Some short stories might have just a few key characters, while epic novels could have dozens.
The number of characters in a story varies greatly. A simple plot might only need two or three main characters to drive the story forward. But a complex tale with multiple subplots could involve a large cast. It all comes down to what the story demands to be engaging and coherent.