Yamask appeared before Team Rocket in a warehouse in Battling For The Love of Bug-Types!. Meowth suggested that they capture it to increase their strength. Jessie agreed and called out her Woobat to battle it, but James claimed it was hungry and he proceeded to feed it. Once it was full, it happily went into James's Poké Ball, the trio welcoming their newest addition with enthusiasm.
In Scare at the Litwick Mansion!, Yamask befriended a group of Litwick in a mansion that Team Rocket was temporarily using as a base. However, it was kidnapped by the Candle Pokémon in an apparent attempt to lure James, Jessie and Meowth into a trap. Yamask teamed up with Jessie's Woobat, Oshawott, Pikachu, and Dwebble to defeat the Litwick and their Lampent leader.
Somtime before An Epic Defense Force!, Yamask helped Team Rocket kidnap Meloetta, who was living in hiding, by distracting Meloetta's protecter: Ridley with its Haze attack. In All for the Love of Meloetta!, Yamask helped uncover Meloetta while Team Rocket were pursuing it. Later in Meloetta and the Undersea Temple! it surrounded Ash and the others with Will-O-Wisp and then revealed Meloetta from its invisable state. Yamask continued to battle Axew and Pansage while Giovanni pursued Ash who had then fled with Meloetta. Then in the next episode Yamask and Woobat used their combined attacks to launch Ash of the top of the ancient temple to prevent him from interfearing with Operation Tempest. When Team Rocket were finally defeated, Yamask allowed them to retreat by cosealing them all with Haze.
Like many of James's Pokémon before it, Yamask is very friendly and is shown to have a great relationship with its Trainer. It is a very thankful Pokémon, as shown when it willingly entered James's Poké Ball after it was given a little food. Unlike most of James's other Pokémon, such as his Victreebel, Cacnea and Carnivine, Yamask doesn't show any kind of special affection to him when coming out of its Poké Ball.
A † shows that the move was used recently, unless all moves fit this case or there are fewer than five known moves.
Trivia
Yamask is the first Ghost-type Pokémon to be officially owned by a main character.
This is the first Pokémon James has added to his party since Carnivine in Two Degrees of Separation!, 212 episodes before. However, since Carnivine was actually obtained when James was still a child, this is his first capture in 259 episodes, with the capture of Mime Jr.