For example, say you want the reader to believe, just for a moment, that a major character is dead. This is really hard to do because major characters almost never die (George R R Martin, notwithstanding), so the reader will always be looking for the trick. For example:
- The character's body is never shown or they died in an ambiguous way.
- The other characters are melodramatic or otherwise overreacting to the death.
- The other characters don't try very hard to determine if the character is really dead.
- A main character dies anywhere other than the climax.
- The character who died is someone normally considered safe (e.g. the hero, a point of view character, an innocent child, etc).
If you want a fake death to be convincing, write it as if it were an actual death. You may not be able to show the body (though if you can, that's even more awesome), but have the other characters in disbelief. Not just disbelief, but actively trying to prove the character is really alive (check breathing, do CPR, call a doctor, etc).
The story might require the fake death to be before the climax (hi, Gandalf), but the longer the story goes without the character showing up, the more the reader will be convinced it actually happened. (Some readers -- not me -- might be in such utter disbelief that they -- not me -- will actually skip ahead in the novel to see if the death really happened. I, of course, would never do this. Not even if [spoiler redacted] from Song of Ice and Fire was struck in the back with an [spoiler redacted]).
You can do this for any kind of secret. Just think of the tricks you look for as a reader, then use them to your advantage.
I probably shouldn't ask where you've seen good character deaths, should I? Too many spoilers. Also the ones I can think of are characters who actually died, but I refused to believe it.