The Shulchan Aruch (Orach Chaim 240:11) rules that it is prohibited to have relations by candlelight. This prohibition is extended to electric lights as well.
Although there should be no direct light on you, indirect light, such as the light from the hall or bathroom, is permissible according to many authorities – as long as it does not actually light up the room and the light source is not directed on the couple.
You can find additional discussion of halachot and guidelines for intimacy on our page on
marital relations.