Casper the Friendly Ghost/WMG

Casper's mother encouraged his friendliness.
In canon where Casper was a deceased person, his mother always taught him to be friendly to people. There are some people who are nice, thus can always expect them to be friendly. Even if no one is being friendly back, his mother taught him not to be bothered by it. His mother's teaching and caring was so strong that when he died, her love was the only thing that kept him from crossing over. That's why he is always searching for friends.

Casper is really an Eldritch Abomination.
He only looks like a cross between a teddy bear and a lightbulb to the viewers because that's what the camera shows him as. This is why (in the comics and both cartoon canons) he was a ghost who had never been a human, and he freaks people out without trying.

Taking a cue from The Simpsons; Casper is the ghost of Richie Rich.
Mr. Rich's money was all in real estate, and when that went south...well, just check out the story of John List.

Poil is the ghost of Gracie Allen.
Okay, Gracie was technically still alive when Poil debuted in the comics, but watching the FOX cartoon version, I can't help but see similarities. Also, her boyfriend Spooky, at least in the early stories, had a fondness for cigars, much like George Burns. And, like George and Gracie, Poil's dippiness drives Spooky nuts, though he genuinely cares about her.