Death is not the final end for your character!

When your character reaches -1 hit points or less, they experience death in the game.

The first affect of death is, they are automatically transported back to their last used savebed (bed to reality). Pretty much means they are safely removed from danger of the attacking monster or trap.  Careful of your own spells though!

Next, your character has lost some percentage of experience points in all skills.  This amount will vary by server configuration.
The only way to restore the lost experience is to regain it by slaying monsters, disarm traps, using spells to slay monsters, etc.

Your character has also lost stat (as in Str, Dex, Con, etc.) points.  More stats are lost at higher character levels. But, this can vary based on server settings.
Don't worry, this stat loss is not permanent.  You can restore the lost stats through a couple of ways.

One way is to consume a Potion of Life which can be found in various shops (Such as House of Healing in Scorn), as quest rewards or as random treasure. Which type of Potion of Life you need will depend on your character level.

High level characters will need a Supreme Potion of Life while a low level character will need a Minor Potion of Life. A single potion will restore any and all lost stats from any and all character deaths they accumulated.

Another way to restore lost stats is if you have the Praying skill, at a certain level in that skill, and following a cult that grants Restoration.
That means, having your character pray long enough on your cult's altar can eventually restore all the lost stats from all deaths.
