How to Make a Simple Traffic Light Circuit: Easy DIY Guide

Joan Jul 01, 2026

Ever wondered how to create a simple traffic light circuit? This fascinating project is not only educational but also a great way to understand the basics of electronics. In this guide, we'll walk you through the process of building a simple traffic light circuit using readily available components. Let's dive in!

Client Challenge
Client Challenge

Before we start, ensure you have the following materials: LEDs (red, yellow, green), resistors (220 ohms and 1 kilo-ohm), a breadboard, jumper wires, and an Arduino board. If you're new to Arduino, don't worry; we'll keep it simple and focus on the basics.

diy traffic 🚦 light
diy traffic 🚦 light

Understanding the Traffic Light Circuit

The traffic light circuit is essentially a simple sequential circuit where each light (red, yellow, green) turns on in sequence. We'll use an Arduino board to control the LEDs, making it an interactive learning experience.

DIY “Traffic light” interactive card. Easy and fun paper electronics project for beginners.
DIY “Traffic light” interactive card. Easy and fun paper electronics project for beginners.

To create this circuit, we'll need to understand the role of each component. LEDs emit light when electricity flows through them, resistors limit the current to prevent damage, and the Arduino board acts as the brain, controlling the flow of electricity.

Setting Up the Arduino IDE

Semáforo casero maqueta facil de hacer tutorial  #CómoSeHace #viralreels #invention #viralvideos
Semáforo casero maqueta facil de hacer tutorial #CómoSeHace #viralreels #invention #viralvideos

Before we start soldering, we need to set up the Arduino IDE on your computer. This software will allow us to write and upload the code that controls our traffic light circuit.

Download the Arduino IDE from the official Arduino website, install it, and open it. You'll need to select the correct board (e.g., Arduino Uno) and port (check Device Manager on Windows or use the command 'ls /dev/tty.*' on Linux/Mac) before we can upload our code.

Writing the Arduino Code

a traffic light sitting on top of a green mat
a traffic light sitting on top of a green mat

Now let's write the simple Arduino code that will control our traffic light circuit. Open a new sketch in the Arduino IDE and paste the following code:

const int redLED = 11;
const int yellowLED = 10;
const int greenLED = 9;

void setup() {
pinMode(redLED, OUTPUT);
pinMode(yellowLED, OUTPUT);
pinMode(greenLED, OUTPUT);
}

void loop() {
digitalWrite(redLED, HIGH);
delay(5000);
digitalWrite(redLED, LOW);
digitalWrite(yellowLED, HIGH);
delay(2000);
digitalWrite(yellowLED, LOW);
digitalWrite(greenLED, HIGH);
delay(5000);
digitalWrite(greenLED, LOW);
}

Building the Traffic Light Circuit

10 DIY Traffic Light Ideas For Kids Crafts
10 DIY Traffic Light Ideas For Kids Crafts

With our code ready, let's move on to building the physical circuit on the breadboard.

Start by inserting the LEDs into the breadboard, ensuring the longer leg (positive, called anode) is in the power rail. Connect one leg of each resistor to the shorter leg (negative, called cathode) of each LED. The other end of each resistor should be connected to one of the Arduino's digital pins (9, 10, and 11 for green, yellow, and red respectively).

Traffic Light Circuit with 555 IC #Shorts
Traffic Light Circuit with 555 IC #Shorts
a person holding a green traffic light with the words help your child learn how to cross the road safely with this craft
a person holding a green traffic light with the words help your child learn how to cross the road safely with this craft
a brown box with two metal buttons on it and a red cord in front of it
a brown box with two metal buttons on it and a red cord in front of it
Arduino Traffic Light Project [With Pedestrian Crossing]
Arduino Traffic Light Project [With Pedestrian Crossing]
Create Interactive Art with Paper Circuits
Create Interactive Art with Paper Circuits
181K views · 1.3K reactions | DIY Traffic Signal Light Circuit | SR Electric | Facebook
181K views · 1.3K reactions | DIY Traffic Signal Light Circuit | SR Electric | Facebook
Traffic light signal model | Traffic light science project for school | Traffic light working model
Traffic light signal model | Traffic light science project for school | Traffic light working model
How to Make Automatic Traffic light Signal Circuit 💞
How to Make Automatic Traffic light Signal Circuit 💞
Traffic signal learning for kids #papercraft #easy #ideas
Traffic signal learning for kids #papercraft #easy #ideas
paper craft | how to make traffic lights| school project #shorts
paper craft | how to make traffic lights| school project #shorts
Can You Legally Run Long Red Lights on a Motorcycle?
Can You Legally Run Long Red Lights on a Motorcycle?
Ev yapımı trafik lambası
Ev yapımı trafik lambası
How to make a simple led traffic light circuit
How to make a simple led traffic light circuit
several different types of wooden toys are arranged on a wall with wires and pegs
several different types of wooden toys are arranged on a wall with wires and pegs
an arduino traffic lights circuit is shown with the words arduino traffic lights on it
an arduino traffic lights circuit is shown with the words arduino traffic lights on it
PAPER CIRCUIT - TRAFFIC SIGNAL
PAPER CIRCUIT - TRAFFIC SIGNAL
Make your own Traffic Light on PCB - NE555 + CD4017
Make your own Traffic Light on PCB - NE555 + CD4017
Traffic Light Craft For Kids: How To Make With Torn Paper
Traffic Light Craft For Kids: How To Make With Torn Paper
How To Make 4 Way Traffic Light at home | easy way to make at home
How To Make 4 Way Traffic Light at home | easy way to make at home
Traffic Light Microbit Project for Beginners Guide with very little coding
Traffic Light Microbit Project for Beginners Guide with very little coding

Powering the Circuit

To power the circuit, connect the longer leg of each resistor (the one not connected to the LED) to the ground rail on the breadboard. Then, connect the power rail to the 5V pin on the Arduino board.

Finally, connect the ground rail on the breadboard to one of the GND pins on the Arduino board. Your traffic light circuit is now complete!

Uploading the Code

With the circuit built, it's time to upload our code to the Arduino board. In the Arduino IDE, click the 'Upload' button (right arrow) or press Ctrl+U. If everything is connected correctly, you should see the LEDs on your breadboard lighting up in sequence - red, yellow, green.

Congratulations! You've just built a simple traffic light circuit. This project not only teaches you about electronics but also introduces you to programming with Arduino. Why not experiment with different delays or add more lights to your circuit? The possibilities are endless!