Either. I can sleep in noise or in quiet, in light or in dark, it doesn't matter. I answered the poll question that says I need background noise, but that's not really true. I don't need it and don't usually have it, but if it's there it doesn't bother me. An uncomfortable bed can sometimes be a problem though. I went through a phase where I couldn't sleep the first night in any bed that wasn't my own (hotels, relatives' homes, etc.) but then slept fine on subsequent nights. That seems to have passed. After my divorce it took about a month before I could sleep at all without taking Ambien. That definitely has passed.