The idea for this thread was blatantly "borrowed" from a thread over on the OD&D proboards. How do you, or would you balance firearms of various sorts with standard fantasy weaponry, magic, etc. Have you done this before? What existing systems do you think do this kind of thing best?
What does "balance" mean?
Firearms displaced every other form of "melee" and "ranged" combat on the battlefield for a reason. If you're wanting "firearms" to be simply a schtick in your game that doesn't do what firearms actually did (supplant every other form of combat in terms of efficiency in killing people) then you simply have to create mechanics that give you want you really want from "firearms" as an abstract way to engage in combat.
So I'm going to ASSUME you don't want to be realistic.
Qualities to consider -
1) Reload times
2) Armor piercing
3) Damage - based on caliber?
4) Range
5) Rarity/Cost - who makes these things?
6) Cultural significance - why do they exist in your fantasy world?
The problem I see is that most people want to pretend that firearms are "too powerful" for fantasy games where ironically casters are abundant and generally cast spells *far* more powerful than most weapons in the game. I say lean into the abstraction of making them as powerful and unique as your setting demands.
If you want to make them less efficient, but cool - just make sure you size them up against other easily available schticks like bows and crossbows and make them distinct from them either in damage or rate of fire. You need to figure out how far you wanna push this.
Think of how granular you want to make it: are options for rifling, optics (however crude), actual cased ammo?, etc. on the table? Firearms really are their own class of weapon, and you simply need to decide how deep you wanna go with it to justify its existence - then explain WHY everyone isn't using them.
Rate of Fire + High Damage is probably the simplest way of doing it. Make powder easily spoiled, but you should make it a SERIOUS choice between normal archery and crossbows and magic.
Armor piercing is the other obvious choice.
If you wanna get into realism... well that's going to change *everything*.
Edit: I know I'm a broken record on this: Savage Worlds does a great job with it. I can take the Deadlands firearms values and literally drop them into ANY Savage Worlds game, and let'er rip. They're not "realistic" - they are GOOD and FUN.