top of page

Smart Street Light Project using Arduino UNO, LDR and LED

Updated: Mar 24

Smart street lights are no more a myth. When we are capable of designing circuits at home and interfacing them with software to control their functions, on a larger scale there are developments happening that can make our lives better and decrease the use of non-renewable resources that we use daily.

All ideas and plans get executed at home or the workplace in the beginning. It's time to learn how to develop or design a smart system and control the devices. So, let's begin with the hardware requirement.

Hardware Requirements

1.Arduino UNO Board.

Develop a stronger concept in Arduino through this article:- What is Arduino?

Arduino UNO
Arduino UNO

#Arduino board is a microcontroller that is used to accept inputs from sensors connected and provide an output action on the desired device connected to it. The sensor inputs can be from light-detecting sensors, motion sensors (Ultrasonic or IR), temperature sensors, etc. The output from this device can be received through other output devices such as LED, Buzzer, Serial monitor, etc.

Buy Arduino UNO from here.

2. Resistors

 1.5k Ohm Resistor
1.5k Ohm Resistor

Resistors are passive devices that restrict the flow of current or divide the voltage through the circuit. The input power passes through these resistors and then to the sensors to avoid damage.

Buy Resistors from here.

3. Jumper Wires

Jumper Wires
Jumper Wires

These are the main components that are used to establish the connections between different devices of the circuit.

Buy Jumper Wires from here.

4. LDR (Light-Dependent Resistor)


LDR is a #photoresistor that works on the principle of #photoconductivity. The surface of the LDR is made with a layer of semiconducting material that is responsible for measuring the light intensity. The principle states that when light falls on the surface of the semiconducting material, the electrons receive energy, and movement is caused inside the material.

When those electrons reach the valence band, electron-hole pairs are formed. This in turn reduces the resistance of the material and the corresponding voltage is given as the output of the device.

Buy LDR from here.

5. Bulb


Electric bulbs, otherwise called incandescent bulbs are electrical components that emit light when a certain amount of power is given to them. Usually, bulbs are manufactured in a wide range of sizes based on the input power capacity. Ex. 1.5V, 13 Watts, etc.

Buy an Electric Bulb from here.

6. Power supply

Power supply
Power supply

DC Power supply is used for electricals components like the electrical bulb. Alternatively, Power supply modules can be used to connect electrical components. In this circuit, we will be using the DC power supply component in the simulation software.

Buy DC Power Supply from here.

7. NPN Transistor

NPN Transistor
NPN Transistor

It is a low-power amplifying #transistor. A common NPN Bipolar Junction transistor (#BJT). This transistor is usually used for Switching purposes as we have used in our circuit. When no current flows through the base, a very small amount of current flows through the emitter and collector. this means the base current allows the transistor to switch off. This is the switching function of the transistor.

Buy Transistors from here.

NOTE: The description of the electrical components is given for reference. We don't need the physical components for this project. The circuit simulation is done in the TinkerCad software.

Software Requirements

TinkerCad circuit simulation software.

TinkerCad Logo
TinkerCad Logo

It is an online simulation software used for circuit design. It has all the electrical components required to built circuits and runs them.

Visit the TinkerCad website.

Circuit Connections and its Working:

The circuit connections are as follows.

Terminal one of the #LDR is connected to the 5V supply pin of the Arduino board. the second terminal of the LDR is connected to the analog pin of the LDR (A5) which is the input. The same terminal is also connected to the Ground terminal of Arduino through the resistor.

The positive terminal of the power supply is connected to one of the terminals of the Bulb. The negative terminal of the power supply is connected to the ground terminal of the Arduino Board. The second terminal of the bulb is connected to the #Emitter pin of the Transistor.

The #collector terminal of the #Transistor is then connected to the ground terminal of the power supply device. Finally, the base terminal of the transistor is connected to any of the Digital pins (D3) of the Arduino Board through the resistor.


Watch the below-given project video for the practical explanation of designing the circuit and to know how the simulation #software works.

Project Video By - Navya Tatiparthi

Simulation software plays a major role in the building of large circuits as they help analyze the working of the circuit before it can be built practically. It helps us create a #virtual design of the circuit we want to build and avoid damages to the circuit if in case we don't know, beforehand about the correct circuit connections.

For more projects through TinkerCad click here.

Simulation software can help us build more effective and efficient projects as it provides validation for the circuit we will be building using the actual components. Smart Light system lays down a basic idea for developing more smart and automated systems. #Design your own circuit, run the code in the software, automate other devices like motors, etc. to build smart systems, and validate your project.

One of the brilliant project You would like to read about is automatic street light project

In today's rapidly advancing world, smart technology has the power to transform our daily lives and contribute to a more sustainable future. One such innovative application is the automatic street light project, which utilizes the LDR (Light-Dependent Resistor) sensor and Arduino microcontroller to create an intelligent lighting system. This project aims to enhance energy efficiency, reduce carbon emissions, and provide safer and well-lit streets for pedestrians and motorists alike. In this article, we will explore the concept of this project and delve into its working, components, and benefits.

Understanding LDR Sensor and Arduino:

The core components of the automatic street light project are the LDR sensor and Arduino microcontroller. The LDR sensor, also known as a photoresistor, reacts to changes in light intensity. When exposed to light, the resistance of the LDR decreases, and conversely, it increases in the absence of light. This property makes it an ideal candidate for detecting ambient light levels.

On the other hand, Arduino, a versatile and popular microcontroller, acts as the brain of the system. It is capable of processing inputs from various sensors, such as the LDR, and accordingly, it can trigger specific actions through its output pins. By utilizing these features, we can develop an automated street lighting system that turns on and off based on the surrounding light conditions.

Working Principle:

The working principle of the automatic street light project revolves around the LDR's ability to sense light intensity and the Arduino's decision-making capabilities. During the day, when natural light is sufficient, the LDR sensor detects the high light intensity and, as a result, exhibits low resistance. This information is conveyed to the Arduino board, which interprets it and ensures that the street lights remain turned off, conserving energy.

As the evening approaches and the natural light diminishes, the LDR sensor detects the drop in light intensity, causing an increase in resistance. This change is communicated to the Arduino, prompting it to take action. The Arduino activates the street lights by energizing the relay or switching on a solid-state relay (SSR) connected to the power supply.

Components Used:

  1. LDR Sensor: To detect ambient light levels and produce corresponding resistance changes.

  2. Arduino Board: To process LDR sensor data and control the street lights.

  3. Solid-State Relay (SSR) or Mechanical Relay: To control the power supply to the street lights.

  4. Power Supply: To provide the necessary electrical power for the street lights.

  5. LED Street Lights: High-efficiency and low-energy consumption lighting solution.

Benefits of the Automatic Street Light Project:

  • Energy Efficiency: The automated system ensures street lights are only activated when required, leading to substantial energy savings.

  • Reduced Carbon Footprint: By optimizing lighting based on ambient conditions, the project contributes to reduced carbon emissions and a greener environment.

  • Cost Savings: Lower energy consumption translates to reduced electricity bills and cost savings for municipalities and local authorities.

  • Safety and Security: Well-lit streets enhance pedestrian and vehicular safety, reducing the risk of accidents and promoting a safer community.

  • Maintenance Convenience: Automated lighting reduces the need for manual switching, easing maintenance efforts.

Automatic street light project explanation :

The automatic street light project is an innovative and eco-friendly initiative aimed at revolutionizing urban lighting systems. This cutting-edge project utilizes advanced technology, including Light-Dependent Resistors (LDRs) or photocells, and microcontrollers to create an intelligent and energy-efficient solution. The system's primary goal is to automatically control the activation and deactivation of street lights based on the surrounding ambient light conditions. During the day, when natural light is sufficient, the LDRs detect the high light intensity, triggering the microcontroller to keep the street lights off, conserving energy. As dusk descends and the natural light diminishes, the LDRs sense the decrease in light intensity, prompting the microcontroller to activate the street lights, ensuring well-lit and safe thoroughfares for pedestrians and motorists. This automatic street light project showcases the power of technology in enhancing sustainability, reducing energy consumption, and providing enhanced safety and security in our urban environments.


The automatic street light project, employing an LDR sensor and Arduino, demonstrates the power of smart technology in creating sustainable and efficient urban lighting solutions. By harnessing the potential of renewable resources and employing intelligent automation, this project showcases how small steps can lead to significant positive impacts on energy consumption and environmental preservation. As we move towards a brighter future, embracing such innovative projects is key to building smart cities that prioritize sustainability and improve the quality of life for all.

Now let us see one more example

Creating Smart Lighting with LDR Sensor and Arduino

Implementing Light Sensing Algorithm with LDR Sensor and Arduino:

To enhance the functionality of our smart lighting project, we focus on the integration of the LDR sensor Arduino. The LDR sensor, also known as the Light-Dependent Resistor, exhibits a change in resistance based on the amount of incident light. By interfacing the LDR sensor with Arduino, we can implement a sophisticated light sensing algorithm that dynamically adjusts the lighting based on changing environmental conditions.

Using the analogRead() function in Arduino, we continuously monitor the LDR sensor's analog readings, which directly correspond to the light intensity. Analyzing these readings allows us to create a responsive lighting system that adapts to different lighting scenarios. For example, during the transition from day to night, the algorithm can gradually adjust the brightness of the connected LED or light bulb, providing a smooth and natural change in illumination levels.

Integrating Hysteresis for Stability:

Stability and reliability are vital in our smart lighting system, where the LDR sensor Arduino combination plays a key role. We incorporate hysteresis into the light sensing algorithm to prevent rapid and unwanted fluctuations in lighting due to minor variations in ambient light. By defining two threshold values: a higher threshold to turn the light on and a lower threshold to turn it off, we reduce flickering and unnecessary switching, ensuring a seamless lighting experience.

Seamless Remote Control with Bluetooth or Wi-Fi Connectivity:

Adding convenience and remote control capabilities to our smart lighting system is possible through Bluetooth or Wi-Fi connectivity, alongside the LDR sensor Arduino integration. By incorporating a Bluetooth or Wi-Fi module, such as HC-05 or ESP8266, users can easily control the lights remotely from their smartphones or other compatible devices.

A dedicated mobile application allows users to adjust light intensity, turn the lights on/off, or even schedule lighting patterns based on their preferences. This connectivity also opens up possibilities for smart city applications, as data from the LDR sensor and other sensors can be sent to a cloud server for further analysis and monitoring.

Maximizing Energy Efficiency with Motion Sensors and Real-Time Clock:

Energy conservation is a crucial aspect of our smart lighting system, made possible by the LDR sensor Arduino integration. To achieve this, we combine the capabilities of motion sensors (PIR sensors) with the LDR sensor. These motion sensors detect human presence and trigger the lights to turn on when someone enters the area. Conversely, if no motion is detected for a certain period, the system can dim the lights or turn them off, reducing unnecessary energy consumption.

Incorporating a real-time clock (RTC) module allows us to program the Arduino to turn on the lights only during specific time frames, such as dusk to dawn. This feature ensures that the smart lighting system operates precisely when needed, further optimizing energy usage and promoting sustainability.

Exploring Machine Learning and AI for Smart Adaptation:

With the LDR sensor Arduino combination as the foundation, we can explore the integration of machine learning and artificial intelligence (AI) to achieve a highly intelligent and adaptive lighting system. By collecting data from various sensors, including the LDR and motion sensors, and feeding it into machine learning models, we can train the system to predict and adapt to specific lighting requirements based on user behavior and environmental conditions.

Through this advanced approach, our smart lighting system can learn from historical data to anticipate peak activity times and automatically adjust lighting accordingly. This optimized approach not only saves energy but also ensures a comfortable and safe environment for users.


By integrating a light sensing algorithm, adding Bluetooth or Wi-Fi connectivity, incorporating hysteresis for stability, maximizing energy efficiency with motion sensors and real-time clocks, and exploring machine learning and AI, we can elevate our smart lighting project that combines LDR sensor Arduino to new heights.

Embracing these advanced technologies and techniques allows us to create a truly intelligent and energy-efficient smart lighting solution. As we continue to innovate and explore new ideas, the future of smart cities will benefit from these advancements, leading to a sustainable and interconnected urban environment for generations to come.

Some facts about smart light based on LDR Arduino :

Through the seamless integration of LDR and Arduino, the smart lighting project becomes a reality, offering energy-efficient and intelligent illumination solutions. The LDR, or Light-Dependent Resistor, serves as the critical light sensing component in the system, while Arduino acts as the central control unit. By connecting the LDR to one of Arduino's analog input pins and using the analogRead() function, the system continuously monitors light intensity. This data enables a sophisticated light sensing algorithm that dynamically adjusts the lighting based on environmental conditions. The LDR Arduino combination enables hysteresis implementation, ensuring stability and smooth transitions in illumination levels. Moreover, the smart lighting system can be seamlessly controlled through Bluetooth or Wi-Fi connectivity, allowing users to adjust light intensity and schedule lighting patterns remotely. By combining motion sensors and a real-time clock, energy efficiency is maximized, as the lights respond to human presence and adhere to specific time frames. The potential for further advancements using machine learning and AI makes this LDR Arduino-based smart lighting system a promising step towards creating sustainable and interconnected smart cities.



Check out more LDR Sensor Arduino based projects :-

Follow us :

Please do follow us i.e #learnelectronicsindia to get daily updates about new blogs, videos, courses, quizzes, and contests.

Check us :

Click on the below links for internship and other opportunities:


Informative and concise! LearnElectronics India always delivers quality content.


Anushka Gupta
Anushka Gupta
Jul 24, 2023

Learn Electronics India deserves all the praise for this exceptional blog post. The smart street light project is a fantastic example of how technology can be utilized to make our lives better while conserving energy. The clarity of the explanations and the inclusion of relevant diagrams ensured a smooth learning experience. This is undoubtedly a must-read for electronics enthusiasts.

bottom of page