Yellow Kirby is only given a story role in two games. In Kirby & The Amazing Mirror, Yellow Kirby is a clone of Kirby created when the original Kirby was split into four. In Kirby Battle Royale, Yellow Kirby is a clone created by the Kirby Printer.
Another Kirby with the same color palette, Keeby, debuts in Kirby's Dream Course. Though they look identical, it has not been stated that they are the same character.
While Yellow Kirby himself does not appear in the anime, when Kirby turns yellow when using the Needle Copy Ability, similar to how that ability appears in Kirby: Nightmare in Dream Land, albeit with orange feet.