The gorilla is a character who appears as the false sole antagonist in the episode "I Had an Accident."
Role in series
"I Had an Accident"
He first appears disguised as Patrick, stuffs the real Patrick and Sandy into a bag and attacks them, which makes SpongeBob finally go outside to save them. The gorilla then grabs SpongeBob and tears him in half. SpongeBob apologizes to Patrick and Sandy for causing everything, declaring that he's no longer scared of going outside but is now terrified of gorillas. They forgive SpongeBob and say that they're also terrified of gorillas.
When SpongeBob asks what the gorilla is doing underwater in the first place, the gorilla panics and flees on George before they can question him any further, leaving everybody, including the family watching the episode on TV, confused.
"Friend or Foe"
The gorilla appears in the live-action Patchy segment as his replacement at The Poop Deck. He is apparently a better cook than Patchy, but after the latter calls him "a smelly, hairy fleabag," the gorilla starts throwing food at Patchy.