Table of Contents
ToggleAn LED turns current into light, while an LDR turns light into a change of resistance. We compare both parts side by side, test them with a multimeter and wire them into one working night lamp circuit.
LED vs LDR is a classic exam and lab question, because the two parts look alike but work in opposite directions. We compare construction, symbols, curves, tests and one circuit that uses both.

What is the difference in LED vs LDR for light circuits?
LED vs LDR comes down to the direction of energy: an LED is a PN junction diode that emits light when forward current flows, while an LDR is a cadmium sulphide resistor whose resistance falls as light rises. A Kingbright L53LID red LED drops about 2.0 V at 20 mA, and a GL5528 LDR reads 10 to 20 kΩ at 10 lux.
| Point | LED | LDR |
|---|---|---|
| Job | Emits light (output) | Senses light (input) |
| Physics | Electroluminescence | Photoconductivity |
| Polarity | Anode and cathode | None, either way round |
| Key rating | VF about 2.0 V at 20 mA (red) | 10 to 20 kΩ at 10 lux |
| Speed | Nanoseconds | 20 to 30 ms |
What Is the Difference Between LED and LDR?
The LED vs LDR difference is simple: an LED is an output device that makes light from current, and an LDR is an input device whose resistance changes with the light falling on it. One is a diode with polarity, the other is a resistor with none.
| Feature | LED | LDR |
|---|---|---|
| Device type | PN junction diode | Photoconductive resistor, no junction |
| Polarity | Long lead is the anode | Non polar, works on AC too |
| Limits | 30 mA DC, 5 V reverse (L53LID) | 100 mW, 150 V (GL5528) |
| Typical use | Indicators, lighting, optocouplers | Dusk switches, night lamps, alarms |
For the full theory of each part, read our companion posts on how an LED works and the LDR working principle.
In LED vs LDR physics, both parts depend on a semiconductor band gap. A red LED emits photons of about 2 eV, and a CdS cell responds best near 520 to 540 nm, close to where the eye is most sensitive.
How Is an LED Built and How Does It Make Light?
An LED is a small PN chip sitting in a reflector cup on the cathode lead, joined to the anode lead by a fine gold wire. When you forward bias it, electrons recombine with holes at the junction and each recombination releases a photon.
This is electroluminescence, and the band gap of the chip sets the colour, not the tint of the epoxy. The epoxy dome only shapes the beam, which the Kingbright L53LID datasheet quotes as a 60 degree viewing angle.
Red at 627 nm: 1240 ÷ 627 = 1.98 eV
So VF is about 2.0 V at 20 mA
Blue at 470 nm: 2.64 eV, VF near 3 V
This is why blue and white LEDs need more voltage than red ones. If junctions are new to you, our notes on what a semiconductor is and the main diode types fill in the background.
How Is an LDR Built and How Does It Sense Light?
An LDR, also called a photoresistor or photocell, is a zigzag track of cadmium sulphide laid between two comb shaped electrodes on a ceramic disc. Light frees electrons in the CdS, so the track conducts better and the resistance falls.
There is no junction, so current flows either way and there is no anode or cathode. The long, narrow zigzag path keeps the dark resistance high, so the change with light is large.
GL5528: R10 = 15 kΩ, γ = 0.7
At 100 lux: 15 × 0.10.7 = 3.0 kΩ
At 1 lux: 75 kΩ
Gamma is the slope of the line on log scales, and GL5528 datasheets give 0.6 to 0.7. Take 15 kΩ, the middle of the 10 to 20 kΩ band, as R10 and trim on the bench.
Wait at least 10 seconds after covering an LDR before reading its dark resistance. The Advanced Photonix datasheet measures it after 10 seconds.
LED vs LDR Symbol, Polarity and Characteristic Curves
In LED vs LDR symbols, the LED is a diode triangle and bar with two arrows pointing out, and the LDR is a resistor box with two arrows pointing in, often inside a circle. The curves follow the same logic: LED current against voltage, LDR resistance against light.

The LED curve stays flat to about 1.6 V and then rises steeply, so a small voltage change gives a big current change. That is why you drive an LED through a series resistor, as our LED resistor calculation guide shows, never from a bare voltage.
The LDR line is nearly straight on log scales, from about 75 kΩ at 1 lux to 3 kΩ at 100 lux. It tells day from night well but measures lux poorly.
- Cheap, robust, two leads and no polarity
- Huge change, from 1 MΩ dark to a few kΩ in room light
- Spectral peak near the human eye
- Slow, and up to a second to recover in the dark
- Wide tolerance, so each circuit needs trimming
- Cadmium is restricted in Europe under RoHS
How to Test LED and LDR With a Multimeter
For the LED vs LDR test, put the LED in diode mode and the LDR in resistance mode. A good LED conducts one way only, while a good LDR reads the same both ways but changes strongly when shaded.
Many meters cannot light a blue or white LED in diode mode, so OL on those colours does not prove a fault. Try 5 V through a 330 Ω resistor instead.

| Symptom | Likely cause | What to check |
|---|---|---|
| LED reads OL both ways | Open LED, or meter too weak for blue or white | Retry with 5 V and 330 Ω |
| LED reads low both ways | Shorted LED, often after running with no resistor | Replace and add a resistor |
| LDR stuck at OL in light | Cracked track or broken lead | Replace the cell |
LED and LDR Circuit: How Does an Automatic Night Lamp Work?
A night lamp shows the LED vs LDR roles clearly: the LDR senses, the LED is the load and a BC547 NPN transistor switches. In daylight the LDR pulls the base low, and in darkness its resistance rises, the base voltage rises and the LED turns on.
R1 and the LDR form a voltage divider on the base, and the transistor starts to conduct at about 0.6 V. Our post on the basics of transistors explains how that small base current controls a larger collector current.

With R1 at 22 kΩ, the base reaches 0.6 V when the LDR falls to about 3 kΩ, which for a GL5528 is close to 100 lux. Below that light level the lamp turns on.
Dark base current: (5 minus 0.7) ÷ 22 kΩ = 0.195 mA
LED current: (5 minus 2.0 minus 0.2) ÷ 150 Ω = 18.7 mA
At 50 lux: RLDR = 4.86 kΩ, base node 0.90 V, lamp on
With a BC547B gain of 200 or more, 0.195 mA of base current allows far more than 18.7 mA, so the transistor saturates. Ohm’s law gives that 18.7 mA, and it stays under the 30 mA limit of the L53LID.
The calculator treats the divider as unloaded, so in a real circuit the base clamps near 0.6 to 0.7 V once the transistor conducts. If you move the LDR to the top, use a voltage divider calculator.
An LED can also act as a weak light sensor, because its junction produces a small voltage when light falls on it. It is much less sensitive than a real photodiode.
Where Are LED and LDR Used in Instrumentation?
In LED vs LDR applications, LEDs serve as indicators, light sources and opto isolator inputs, while LDRs serve as slow, cheap light sensors. Plants use far more LEDs, because fast light sensing has moved to photodiodes.
The optocoupler working principle is the clearest case of an LED used as a signal source. On conveyors, the photoelectric sensors in automation pair an LED emitter with a fast receiver, not an LDR.
If your night lamp flickers at dusk, check whether the LED light reaches the LDR. Shield the sensor, or add hysteresis with a comparator.
Which Light Sensor Should You Choose Instead of an LDR?
Choose an LDR for slow, low cost switching, a photodiode for fast or accurate measurement, and a phototransistor for more signal at moderate speed. In an LED vs LDR pairing, the LED only supplies the light.
Resistance falls with light, logarithmic, tens of ms.
Current proportional to light, fast and linear.
Photodiode with built in gain, microsecond speed.
Our comparison of photodiode and phototransistor covers speed and gain in detail. For an accurate light reading, a photodiode with a transimpedance amplifier is the standard front end.
- Only day or night switching? An LDR is enough.
- Need response faster than about 50 ms? Use a photodiode.
- Selling in Europe? Check RoHS status before using CdS.
- Driving an LED? Size the resistor for 20 mA or less.
For the LED side of the night lamp, the LED resistor calculator gives the series resistor in one step. For a sharper switch point, our guide to comparator circuits shows how to replace the single transistor.
LED vs LDR FAQ
In LED vs LDR terms, an LED emits light when forward current flows, while an LDR changes resistance with light. A red LED drops about 2.0 V at 20 mA, and a GL5528 LDR reads 10 to 20 kΩ at 10 lux.
Use R = R10 × (10 ÷ lux) raised to gamma, where R10 is the resistance at 10 lux. For a GL5528 with R10 of 15 kΩ and gamma 0.7, at 100 lux you get 15 × 0.2 = 3.0 kΩ.
Check the LED in diode mode with the red probe on the long lead, and expect about 1.6 to 2.0 V for red and OL when reversed.
A good LDR on the 2 MΩ range reads a few kΩ in room light and hundreds of kΩ when covered.
Flicker usually means the LED light reaches the LDR, or the light sits right at the switch point with no hysteresis. A lamp that stays on in daylight often has an open LDR, which leaves the base pulled high by R1.
A photodiode is far better, because it responds in microseconds or less while a GL5528 LDR needs 20 ms to rise and 30 ms to fall. Choose an LDR only for slow jobs such as day and night switching, and use a photodiode for pulse counting.
Related Articles
- LED Working Principle
- LDR Light Dependent Resistor Working Principle
- Photodiode vs Phototransistor Key Differences
- Optocoupler Working Principle
- IR Sensor Working Principle
External References
- Advanced Photonix PDV P8005 CdS Photocell Datasheet (PDF)
- SparkFun: Light Emitting Diodes, Get the Details
- Wikipedia: Photoresistor
What We Learn Today
- The LED vs LDR difference is one of direction, because an LED turns forward current into light while an LDR turns light into resistance.
- Test an LED in diode mode with the red probe on the long lead, and test an LDR on a high ohms range while shading it.
- An LDR and resistor divider driving a BC547 transistor make a simple night lamp that lights a red LED below about 100 lux.

