i want to operate a relay with an ARDUINO UNO, but i want to use a separate power supply for the relay. Ive seen relays with VCC and jVCC (dont know what that is), but mine only has this pins: GND, IN1, IN2, VCC. how should i connect it to the Arduino and the external power supply? enter image description here

  • 2
    That doesn't look like a relay board set up for separate power supply. Those that do will have an opto-isolator per relay. Aug 18, 2017 at 20:54
  • jVCC (where avail) is used to drive the magnetic relay coils, VCC is used to drive the logic/LEDs.
    – dandavis
    Aug 19, 2017 at 12:16

3 Answers 3


This relay is designed to operate on 5V.

Most commonly this will come from the Uno's 5v pin.

If you want to externally power the relay itself then make sure to connect the +5 to the Vcc on the relay board and the - lead to the GND on the relay board.

Uno's GND must also be connected to the GND on the relay so the Digital outputs from the Uno will properly control the IN1 and IN2 inputs to the relay board.

The Uno has multiple GND connections so it makes the most sense to connect the - to one of them then another to the relay.

Note that the Uno's 9V Vcc external power comes in through the barrel connector on the Uno itself. The Uno will pass power through its internal regulator to provide 5v at the appropriate connection.

If you are switching external devices that run on 120V it would be on the screw-terminal side of the board only.

To prevent accidental activation of the relays, note that this particular board is ACTIVE-LOW which means that as you initialize the output pins you should first set them HIGH so setting the pinMode will not default to LOW which would trigger the relay.

In the setup() section, using pins D5 and D6 as an example:

digitalWrite(5,HIGH); pinMode(5,OUTPUT);
digitalWrite(6,HIGH); pinmode(6,OUTPUT);
  • 1
    The question is "but i want to use a separate power supply for the relay".
    – MatsK
    Aug 19, 2017 at 22:33

The Arduino and the external PSU should have the GND or - connected with each other.

Then connect the external PSU + or Vcc to the relay boards Vcc.


External psu to gnd and vcc, in1 and in2 to arduino pins which control each relay (on is LOW) and most importantly gnd also to arduino gnd.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.