NEVER!!!
No DMPCs, no GMPCs, no NPCs that are members of "the party" the PCs belong to, no NPCs that "adventure" alongside the PCs.
PCs are meant to be the movie stars and rock gods. The PCs are the main characters of the movie or TV show or novel or story. The PCs are unique in that regard. They may not be protagonists, or heroes, or even all that special, but they are the headliners. The emergent narrative focuses on their deeds.
NPCs are the extras, they operate as secondary characters at best. Ultimately they are not important. They may change over time, and may even feature prominently in the narrative for a time, but the story is not about them, it's about what the PCs are doing.
I refuse to participate in games where the GM has their own PCs. The GM does not need a PC, they have dozens or hundreds or even thousands of NPCs to run, they do not need their own PCs!
Players get a PC. Players focus on running their PC. GMs get oodles of NPCs to focus on, in addition to running "the world" the PCs engage in during their exploits. GMs that want to run their own PC should not GM and instead be a Player and play in a game with a different person as the GM. IMHO anyway.