Progression
How to claim a bed and set spawn in Valheim
Place a bed under shelter and use it to claim it as your spawn point.

1. Build a covered room
Leave space to reach the bed. If sleep is blocked, read the interaction message and fix the requirement it names.
2. Keep a fire nearby
Place a suitable fire close enough for sleeping and vent smoke safely. A roof can shelter the fire from rain.