The Night-Light [MINI PROJECT]

This is a circuit that turns on a light when it gets dark.

The sensor we use here is a photoresistor, also called Light-Dependent Resistor (LDR). The resistance of the photoresistor is high when there is little to low light, or low when there is a lot of light.

The photoresistor and the resistor R1 make up a voltage divider. So when the resistance of the photoresistor is high, the voltage on the base of the resistor becomes high and turns on the transistor. When the resistance of the photoresistor is low, the voltage on the base becomes low and turns off the transistor.