Cirkit Designer Logo
Cirkit Designer
Your all-in-one circuit design IDE
Home / 
Component Documentation

How to Use 12v Relay: Examples, Pinouts, and Specs

Image of 12v Relay
Cirkit Designer LogoDesign with 12v Relay in Cirkit Designer

Introduction

A 12V relay is an electromechanical switch that uses an electromagnetic coil to open or close its internal contacts. This allows a low-power control signal to manage a high-power circuit, making it an essential component in many electronic and electrical systems. Relays are widely used for automation, isolation, and control purposes.

Explore Projects Built with 12v Relay

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
ESP32-Controlled DC Motor with Dual Relay System
Image of LED Show v2: A project utilizing 12v Relay in a practical application
This circuit controls a DC motor using two 12V relays, which are powered by a 12V supply through a barrel jack. The relays are configured to switch the motor's connections, allowing for control over its operation.
Cirkit Designer LogoOpen Project in Cirkit Designer
Battery-Powered Relay Control System with Directional Switch
Image of Skema Lampu D2: A project utilizing 12v Relay in a practical application
This circuit involves a 12V battery powering a relay system controlled by a directional switch. The relays are connected through terminal blocks and are used to switch between different outputs, indicated by the AdaGator Top components.
Cirkit Designer LogoOpen Project in Cirkit Designer
ESP32-Based Wi-Fi Controlled Solenoid Valve with Relay
Image of fyp: A project utilizing 12v Relay in a practical application
This circuit uses an ESP32 microcontroller to control a 12V relay, which in turn operates a plastic solenoid valve. The ESP32 toggles the relay on and off every second, allowing the solenoid valve to open and close accordingly.
Cirkit Designer LogoOpen Project in Cirkit Designer
Battery-Powered 4-Channel Relay Control with LED Indicators
Image of RELLAY BOARD TEST: A project utilizing 12v Relay in a practical application
This circuit consists of a 5V battery powering a 4-channel relay module, which controls four LEDs (red, yellow, green, and blue) through individual resistors. Each relay channel is activated by a corresponding SPST toggle switch, allowing manual control of the LEDs.
Cirkit Designer LogoOpen Project in Cirkit Designer

Explore Projects Built with 12v Relay

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Image of LED Show v2: A project utilizing 12v Relay in a practical application
ESP32-Controlled DC Motor with Dual Relay System
This circuit controls a DC motor using two 12V relays, which are powered by a 12V supply through a barrel jack. The relays are configured to switch the motor's connections, allowing for control over its operation.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of Skema Lampu D2: A project utilizing 12v Relay in a practical application
Battery-Powered Relay Control System with Directional Switch
This circuit involves a 12V battery powering a relay system controlled by a directional switch. The relays are connected through terminal blocks and are used to switch between different outputs, indicated by the AdaGator Top components.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of fyp: A project utilizing 12v Relay in a practical application
ESP32-Based Wi-Fi Controlled Solenoid Valve with Relay
This circuit uses an ESP32 microcontroller to control a 12V relay, which in turn operates a plastic solenoid valve. The ESP32 toggles the relay on and off every second, allowing the solenoid valve to open and close accordingly.
Cirkit Designer LogoOpen Project in Cirkit Designer
Image of RELLAY BOARD TEST: A project utilizing 12v Relay in a practical application
Battery-Powered 4-Channel Relay Control with LED Indicators
This circuit consists of a 5V battery powering a 4-channel relay module, which controls four LEDs (red, yellow, green, and blue) through individual resistors. Each relay channel is activated by a corresponding SPST toggle switch, allowing manual control of the LEDs.
Cirkit Designer LogoOpen Project in Cirkit Designer

Common Applications and Use Cases

  • Home Automation: Controlling lights, fans, and appliances.
  • Automotive Systems: Switching headlights, horns, and other vehicle electronics.
  • Industrial Control: Managing motors, pumps, and solenoids.
  • Microcontroller Projects: Interfacing with Arduino, Raspberry Pi, or other microcontrollers to control high-power devices.

Technical Specifications

Below are the key technical details of a standard 12V relay:

Parameter Value
Operating Voltage 12V DC
Coil Resistance ~400Ω to 500Ω (varies by model)
Switching Voltage Up to 250V AC / 30V DC
Switching Current Typically 10A (check datasheet)
Contact Configuration SPDT (Single Pole Double Throw) or DPDT (Double Pole Double Throw)
Isolation Electrical isolation between control and load circuits
Dimensions Varies by model (e.g., 28mm x 12mm x 15mm for mini relays)
Operating Temperature -40°C to +85°C

Pin Configuration and Descriptions

The 12V relay typically has 5 pins for SPDT configuration. Below is the pinout:

Pin Number Name Description
1 Coil (+) Positive terminal of the electromagnetic coil (connect to 12V DC).
2 Coil (-) Negative terminal of the electromagnetic coil (connect to ground).
3 Common (COM) Common terminal for the load circuit.
4 Normally Open (NO) Open circuit when the relay is inactive; closes when the relay is activated.
5 Normally Closed (NC) Closed circuit when the relay is inactive; opens when the relay is activated.

Usage Instructions

How to Use the 12V Relay in a Circuit

  1. Power the Coil: Connect the coil terminals (pins 1 and 2) to a 12V DC power source. Use a transistor or MOSFET to control the coil with a low-power signal from a microcontroller.
  2. Connect the Load:
    • Connect the load's power source to the COM pin (pin 3).
    • Connect the load to either the NO pin (pin 4) or the NC pin (pin 5), depending on the desired behavior:
      • Use NO if the load should be powered only when the relay is activated.
      • Use NC if the load should be powered when the relay is inactive.
  3. Control the Relay: Use a microcontroller or switch to activate the relay by energizing the coil.

Important Considerations and Best Practices

  • Diode Protection: Always place a flyback diode (e.g., 1N4007) across the coil terminals to protect the circuit from voltage spikes caused by the collapsing magnetic field when the relay is deactivated.
  • Current Ratings: Ensure the relay's contact ratings (voltage and current) are sufficient for the load.
  • Isolation: Use optocouplers or transistors to isolate the control circuit from the high-power load circuit.
  • Power Supply: Provide a stable 12V DC supply to the relay coil to ensure reliable operation.

Example: Using a 12V Relay with Arduino UNO

Below is an example of how to control a 12V relay using an Arduino UNO:

// Define the pin connected to the relay module
const int relayPin = 7;

void setup() {
  pinMode(relayPin, OUTPUT); // Set the relay pin as an output
  digitalWrite(relayPin, LOW); // Ensure the relay is off initially
}

void loop() {
  digitalWrite(relayPin, HIGH); // Activate the relay
  delay(5000); // Keep the relay on for 5 seconds
  digitalWrite(relayPin, LOW); // Deactivate the relay
  delay(5000); // Keep the relay off for 5 seconds
}

Note: Ensure the relay module has a built-in transistor and flyback diode for safe operation with the Arduino.

Troubleshooting and FAQs

Common Issues and Solutions

  1. Relay Not Activating:

    • Cause: Insufficient voltage or current to the coil.
    • Solution: Verify the power supply provides 12V DC and sufficient current. Check connections.
  2. Load Not Switching:

    • Cause: Incorrect wiring of the load circuit.
    • Solution: Double-check the connections to the COM, NO, and NC pins.
  3. Microcontroller Resetting:

    • Cause: Voltage spikes from the relay coil.
    • Solution: Add a flyback diode across the coil terminals.
  4. Relay Clicking Rapidly:

    • Cause: Unstable control signal or insufficient power supply.
    • Solution: Stabilize the control signal and ensure the power supply can handle the relay's current draw.

FAQs

  • Q: Can I use a 12V relay with a 5V microcontroller?
    A: Yes, but you need a transistor or relay driver circuit to amplify the 5V signal to 12V for the relay coil.

  • Q: What is the purpose of the flyback diode?
    A: It protects the circuit from voltage spikes generated when the relay coil is de-energized.

  • Q: Can I use the relay to switch AC loads?
    A: Yes, as long as the load's voltage and current are within the relay's rated specifications.

  • Q: How do I know if the relay is SPDT or DPDT?
    A: Check the relay's datasheet or count the number of pins. SPDT relays typically have 5 pins, while DPDT relays have 8 pins.