This can be done quickly into your playthrough.
Firstly, you will have to progress far enough into your hand crafting recipes (press
) to unlock Comfy Padding and Makeshift Bed Sheet. After you can craft those, press
to bring up the Blueprints menu. You should see an option called Flimsy Bed. Click it, and find a spot to place it. If it is highlighted in red when you try to place, that means something is blocking it, and you'll have to find another place to put it. If it's not red, place it down.
Go near your newly placed bed and hit
to add your Comfy Padding. If you do not have comfy padding in your inventory, craft some. After hitting
to add the padding, hit
to Craft it. After a short bar, your bed will almost be ready.
The next thing you need to do is place your blanket on the bed. After placing the blanket on your bed, hit
to Sleep in your bed. You'll be brought to a screen asking if you want to Save, Sleep, or Save & Sleep. Anything will net you the achievement except Save, so pick either of the other ones.
Note: You may have trouble sleeping if there are monsters nearby. Also, it does not have to be nighttime to sleep.