No data
Summary: A photoresistor, or light-dependent resistor (LDR), is a passive electronic component that decreases in resistance as light intensity increases. Driven by the expansion of IoT and smart home automation, the global photoresistor market is projected to reach $553.75 million by 2025. This guide covers LDR working principles, circuit diagrams, types, and step-by-step Arduino integration.
Photoresistor or light-dependent resistor (abbreviated as LDR) or photoconductor is a special resistor made of semiconductor materials such as cadmium sulfide or cadmium selenide. Its working principle is based on the internal photoelectric effect. The stronger the light, the lower the resistance value. With the increase of the light intensity, the resistance value decreases rapidly, and the bright resistance value can be as small as 1KΩ or less. The photoresistor is very sensitive to light, and it shows a high resistance state when there is no light, and the dark resistance can generally reach 1.5MΩ.
This article includes an overview of the basic information of the photoresistor and two Arduino tutorials for the photoresistor. The content is very comprehensive and detailed. You can choose the part you want to read or read the full text. We hope this article is helpful to you!
A photoresistor (also known as a light-dependent resistor, LDR, or photo-conductive cell) is a passive electronic component that decreases its electrical resistance as the luminosity on its sensitive surface increases.
The standard schematic symbols for a photoresistor are generally represented by the designators "RL", "RG", or "R", often accompanied by a resistor icon enclosed in a circle with incoming arrows indicating light. The following figure shows the schematic symbols of the photoresistor.

Figure1. Photoresistor Symbol
Recommended Reading: To learn more about Resistor Symbol.
(1) The structure of the photoresistor
A photoresistor is primarily composed of a photosensitive semiconductor layer, a glass substrate or moisture-proof film, and comb-shaped ohmic electrodes.

Figure2. The Structure of Photoresistor
The materials used for manufacturing photoresistors are primarily semiconductors such as metal sulfides, selenides, and tellurides. Usually, coating, spraying, sintering and other methods are used to make a very thin photoresistor and comb-shaped ohmic electrode on the insulating substrate, and then the lead is taken out and encapsulated in a sealed housing with a light-transmitting mirror to prevent moisture from affecting its sensitivity.
How does a photoresistor work
The working principle of a photoresistor is based entirely on the internal photoelectric effect, where incident light energy excites electrons into the conduction band, thereby lowering the component's electrical resistance.
A voltage is applied to the metal electrodes at both ends of the photoresistor, and a current flows through it. When irradiated with light of a certain wavelength, the current will increase with the increase of light intensity, thereby achieving photoelectric conversion. After the incident light disappears, the electron-hole pairs generated by the photon excitation will recombine, and the resistance of the photoresistor will return to its original value.
The photoresistor has no polarity and is purely a resistive device. It can be used with either DC voltage or AC voltage. The conductivity of a semiconductor depends on the number of carriers in the semiconductor conduction band.
Simply put, it is the effect of transitions between energy levels. Photons at different wavelengths have different energies, and an electron can only absorb one photon. After an electron absorbs a photon, whether it can be converted from non-conductive to conductive electrons depends on the photon’s Energy, and the number of electrons that can conduct electricity determines the resistance of the photoresistor. Therefore, the light wavelength also affects the resistance of the photoresistor.
Recommended Reading: See more about light sensor, wavelength, spectrum and photometric physical quantity.
The internal photoelectric effect is a phenomenon where the absorption of photons causes a change in the electrical conductivity of a semiconductor material. This differs from the external photoelectric effect, which involves the complete escape of electrons from the material's surface.
The internal photoelectric effect can be divided into two main categories:
Photoconductivity
The photoconductive effect is one of two internal photoelectric effects. The internal photoelectric effect refers to the phenomenon that the electrical conductivity of a semiconductor exposed to light changes or a photo-induced electromotive force is generated. Among them, the phenomenon that the conductivity of the semiconductor changes due to light is called the photoconductivity effect.

Figure3. Energy Level of Atom
The photovoltaic effect occurs when a P-type and N-type semiconductor are combined, creating a P-N junction. The process unfolds as follows:

Figure4. Photovoltaic Effect

Figure5. Schematic Circuit
Module parameters:
(3)Photoresistor application circuit diagram
The following figure is a schematic diagram of the application of the photoresistor in the light control switch. The photoresistor is connected in series with the resistor R1. When there is no light, that is, the voltage across R1 does not reach the turn-on voltage of the Q1 transistor. Once exposed to light, the resistance of the photoresistor drops rapidly. The voltage across R1 rises and the transistor turns on, which causes the transistor Q2 in the subsequent stage to turn on, and finally, the switch K opens and the bulb works.

Figure6. Common Photoresistor Application Circuit Diagram
(4) Photoresistor dimming circuit
The following figure is a typical light-controlled dimming circuit. Its working principle is: when the surrounding light becomes weak, the resistance of the photoresistor RG increases, which increases the partial voltage added to the capacitor C, which in turn makes the thyristor's conduction angle is increased to achieve the purpose of increasing the voltage across the lamp. Conversely, if the surrounding light becomes brighter, the resistance of RG decreases, resulting in a smaller conduction angle of the thyristor, and the voltage across the lamp decreases at the same time, dimming the light, thereby controlling the illuminance of the lamp.

Figure7. Photoresistor Dimming Circuit
Note: The rectifier bridge in the above circuit must be a DC pulsating voltage, and it cannot be converted into a smooth DC voltage by capacitor filtering, otherwise the circuit will not work properly. The reason is that the DC pulsating voltage can not only provide the basic conditions for the zero-crossing shutdown of the thyristor, but also enable the charging of the capacitor C to start from zero every half cycle, and accurately complete the synchronous phase-shift triggering of the thyristor.
Based on material composition, photoresistors are classified into intrinsic (pure semiconductor) and extrinsic (doped semiconductor) types. Polycrystalline and single crystal photoresistors can also be divided into cadmium sulfide (CdS), cadmium selenide (CdSe), lead sulfide (PbS), lead selenide (PbSe), indium antimonide (InSb) photoresistors, etc.
| Spectral Type | Common Materials | Primary Applications (2026) |
|---|---|---|
| Ultraviolet (UV) | Cadmium sulfide, Cadmium selenide | UV detection, environmental monitoring |
| Infrared (IR) | Lead sulfide, Lead telluride, Indium antimonide | Astronomical detection, non-contact measurement, IR communication |
| Visible Light | Selenium, Silicon, Germanium, Zinc sulfide | IoT smart lighting, automatic street lights, exposure devices |
(1) Ultraviolet photoresistor: sensitive to ultraviolet rays, including cadmium sulfide, cadmium selenide photoresistors, etc., used to detect ultraviolet rays.
(2) Infrared photoresistors: mainly lead sulfide, lead telluride, and lead selenide. Photoresistors such as indium antimonide are widely used in missile guidance, astronomical detection, non-contact measurement, human disease detection, infrared spectroscopy, infrared communication and other national defense, scientific research, and industrial and agricultural production.
(3) Visible light photoresistors: including selenium, cadmium sulfide, cadmium selenide, cadmium telluride, gallium arsenide, silicon, germanium, zinc sulfide photoresistors, etc. Mainly used in various photoelectric control systems, which account for a significant portion of the projected $553.75 million global photoresistor market in 2025. Applications include IoT smart lighting, automatic turning on and off of navigation lights, street lights and other lighting systems, automatic water supply and automatic water stop devices, automatic protection devices on machinery and "position detectors" Thickness detectors for thin parts, automatic exposure devices for cameras, photoelectric counters, smoke alarms, photoelectric tracking systems, etc.

Figure8. Light Dependent Resistor
The main parameters of a photoresistor define its operational limits, sensitivity, and response time in various lighting conditions.

Figure9. LDR
(1) Dark resistance and bright resistance
The difference between bright current and dark current is called photocurrent.
Obviously, the larger the dark resistance of the photoresistor, the better, and the smaller the bright resistance, the better, that is, the dark current should be small and the bright current should be large, so the sensitivity of the photoresistor is high.

Figure10. Bright Current and Dark Current
(2) Volt-ampere characteristics
Under a certain illuminance, the relationship between the voltage applied across the photoresistor and the current flowing through the photoresistor is called the volt-ampere characteristic.
The volt-ampere characteristic of the photoresistor is approximately a straight line, and there is no saturation phenomenon. Due to the limitation of power dissipation, the voltage across the photoresistor cannot exceed the maximum operating voltage during use. The dotted line in the figure is the allowable power consumption curve, from which the normal operating voltage of the photoresistor can be determined.
(3) Photoelectric characteristics
The relationship between the photocurrent of the photoresistor and the illuminance is called the photoelectric characteristic. The photoelectric characteristics of the photoresistor are nonlinear. Therefore, it is not suitable as a detection element, which is one of the shortcomings of the photoresistor. In automatic control, it is often used as a switching photoelectric sensor.

Figure11. Characteristics of the Photoelectric Effect
(4) Spectral characteristics
For incident light of different wavelengths, the relative sensitivity of the photoresistor is different. The spectral characteristics of various materials are shown in Figure 2.6.4. It can be seen from the figure that the peak value of cadmium sulfide is in the visible light region, and the peak value of lead sulfide is in the infrared region. Therefore, when selecting the photoresistor, the types of components and light sources should be considered in order to obtain satisfactory results.
(5) Frequency characteristics
When the photoresistor is exposed to pulsed light, the photocurrent will reach a steady-state value after a period of time. When the light suddenly disappears, the photocurrent will not be zero immediately. This shows that the photoresistor has time-delay characteristics. Because different materials have different time delay characteristics of photoresistors, their frequency characteristics are also different. Figure 2.6.5 shows the relationship between the relative sensitivity Kr and the light intensity change frequency f. It can be seen that the use frequency of lead sulfide is much higher than that of thallium sulfide. However, most photoresistors have large time delays, so they cannot be used in situations where fast response is required. This is a defect of photoresistors.
(6) Temperature characteristics
Like other semiconductor devices, the photoresistor is greatly affected by temperature. When the temperature increases, its dark resistance will decrease. Changes in temperature also have a great influence on spectral characteristics. Figure 2.6.6 is the spectral temperature characteristic curve of the lead sulfide photoresistor. It can be seen from the figure that its peak value moves to the short wavelength direction as the temperature rises. Therefore, in order to improve the sensitivity, or in order to receive far-infrared light, cooling measures are taken.

Figure12. Temperature Characteristics
Spectral Temperature Characteristics of Lead Sulfide Photoresistor
A commonly used photoresistor is a cadmium sulfide photoresistor, which is made of semiconductor material. The resistance of the photoresistor changes with the intensity of the incident light (visible light). Under dark conditions, its resistance (dark resistance) can reach 1~10MΩ; under strong light conditions (100LX), its resistance (Bright resistance) Only a few hundred to thousands of ohms. The sensitivity of the photoresistor to light (the spectral characteristics) is very close to the human eye's response to visible light (0.4~0.76) μm. As long as the human eye can sense the light, it will cause its resistance to change. Therefore, when designing the light control circuit, the incandescent bulb (small electric bead) light or natural light is used as the control light source, which greatly simplifies the design.

Figure13. Photoresistor Characteristic Curve
The corresponding resistance change of the photoresistor with the intensity of the incident light is not linear, so it cannot be used for the linear conversion of the photoelectricity. This is where the user should pay attention. Beginners can purchase a photoresistor (MG45 type), at night a 60~100W incandescent lamp, use a multimeter to directly measure the resistance of the photoresistor. When measuring, the photoresistor should be aimed at the light of the incandescent lamp, and then gradually distance from the lamp (from near to far), observe the change of the resistance value indicated by the multimeter, and the special characteristics of the photoresistor can be visually verified.
Commonly used photoresistor models are sealed MG41, MG42, MG43 and unsealed MG45 (cheap price). Their rated power is below 200mW.
LED Control with LDR (Photoresistor) and Arduino
In the data collection of modern smart home systems, the measurement of light intensity is highly necessary. For example, indoor IoT lighting can be automatically adjusted according to the intensity of the light to provide users with the most comfortable environment. The tutorial here will use a photoresistor to cooperate with Arduino to complete the light data collection.
(1) Materials
(2)Wiring method

Figure14. Wiring Method
The resistance of photosensitive resistors is very high in the condition of no light. The stronger the light, the smaller the resistance. By measuring the voltage variation on both sides of the photosensitive resistance, the variation of the photosensitive resistance can be known and the light intensity can be obtained. In the connection diagram, we find that a partial voltage resistor is connected in series for the photosensitive resistor.

Figure15. Circuit
In the above figure, RL is a photoresistor, R1 is a series resistor, Vout=RLR1+RL∗Vin, in the dark, the resistance of RL will be very large, so Vout is also very large, close to 5V. Once the light is irradiated, the value of RL will decrease rapidly, so Vout will decrease accordingly. It can be seen from the above formula that R1 should not be too small, preferably around 1k~10k, otherwise the ratio will not change significantly.
(3) Code
The code part is very simple, just read the analog value of the interface connected to the photoresistor.
1 light = analogRead(0);
Open the serial monitor of Arduino, illuminate the photoresistor with the flashlight of the mobile phone, and observe the result:
2 Serial.println("lignt :");
3 Serial.println(light);
(1) Materials
(2)Wiring method

Figure16. Wiring Method
(3)Program
#define AD5 A5 //Define analog port A5
#define LED 13 //Define digital port 13
int Intensity = 0;//Illuminance value
void setup() //Program initialization
{
pinMode(LED, OUTPUT);//Set LED to output mode
Serial.begin(9600);//Set baud rate 9600
}
void loop() // Program body loop
{
Intensity = analogRead(AD5); //Read the value of analog port AD5 and save it in the Intensity variable
Serial.print("Intensity = "); //Serial output "Intensity = "
Serial.println(Intensity); //The serial port outputs the value of the Intensity variable and wraps
delay(500); //Delay 500ms
}
(4) Power on, view serial data
Test Results:

Figure17. Test Results
The above data is the change of the value with the flashlight and no light.
(5) Summary
The positive and negative poles are reversed and the values are reversed. The larger the resistance value, the larger the change range. Using 5V, the range is larger than 3.3V.
Recommended Reading: Arduino&mBlock light sensor
Photoresistors, potentiometers, and thermistors are all ________.
A. Outputs
B. Digital inputs
C. Analog inputs
D. Throughputs
Answer: C
A photoresistor is a passive component that changes resistance based on light intensity, making it slower but easier to use. A photodiode is an active semiconductor with a P-N junction that converts light into current, offering much faster response times for high-speed applications.
A photoresistor is fundamentally an analog component. Its resistance changes continuously in response to varying light levels. However, when paired with a microcontroller like an Arduino and a voltage divider, its analog signal can be easily converted into digital data.
Photoresistors are primarily categorized into intrinsic and extrinsic types. Intrinsic photoresistors use pure semiconductors like silicon, while extrinsic types use doped materials to detect longer wavelengths, such as infrared light, making them ideal for specialized sensors.
In modern IoT and smart home systems, photoresistors act as ambient light sensors. They automatically trigger actions like turning on outdoor security lights, adjusting indoor smart bulb brightness, or activating motorized blinds when sunlight reaches a specific threshold.
Kynix was founded in 2008, specializing in the electronic components distribution business. We adhere to honesty and ethics as our business philosophy and have gradually established an excellent reputation and credibility in our international business. With the accurate quotation, excellent credit, reasonable price, reliable quality, fast delivery, and authentic service, we have won the praise of the majority of customers.
Join our mailing list!
Be the first to know about new products, special offers, and more.
Recent Posts

We'd love to hear from you! Feel free to share your thoughts and comments below. Rest assured, your email address will remain private.
© 2008-2026 kynix.com all rights reserved.