Turn on/off any PC with an ATX PSU and InfraRed remote

My HTPC has/had a CIR which allowed me to turn it on via my Harmony remote, but one day it stopped working and my attempts to fix it totally broke it.
So my 1st idea was I'll buy a new CIR device, but I couldn't find any.
My 2nd idea was get a new Motherboard, but that meant new CPU (Skylake i7-6700k) + RAM (DDR4) bcos there's no point getting a new Mobo if your not getting the latest and greatest, and I couldn't find any which turned on via IR.
My 3rd idea was build something :), this turned out to be ridiculously easy.

What would I need? Some way of automating pressing the button for 2 seconds, bcos that turns the PC on and off, and something to accept an IR signal.
I knew ATX PSU's have a 5v standby power supply, so IR relay would need to operate on 5v.

A quick google didn't help, so I went to Alibaba and found exactly what I was looking for, a 5v IR relay with timer function. I then went to eBay bcos I prefer the buying experience. Found the same 5v Programmable relay for $5 how awesome is that!?
3 weeks later it arrives and I proceed to install it. 

  1. Test relay to ensure it works.
  2. Program your universal IR remote unless you want to use the included one. My Harmony Elite had a really hard time learning the IR command, and even when it did it wouldn't work the 1st time, but it eventually learnt the command.
  3. Set relay time to 2 seconds, shorter will turn it on, but may not turn it off. 4 seconds will force a power cut.
  4. If required extend the infrared phototransistor, black shiny thing with 3 pins. I extended mine by 30cm to have it sit outside the case.
  5. Either find 5v on a motherboard USB pin header (I used the USB2 header as pictured and I had to enable Asmedia USB 3.1 battery in the BIOS to have 5v constantly supplied to the relay) or get it directly from the ATX connector.
  6. Supply 5v to the IR relay power input.
  7. Run 2 wires from relay output NO (normally open) + COM to the Power Switch pins on your motherboard front panel pins.
  8. T join the case front panel power switch to the Power Switch pins on your motherboard or join them on the relay (pictured) so you can still use the normal power switch.
  9. Test. Apart from the Harmony learning command issue, it has worked flawlessly for the past 2 weeks (update: +2 years) and I like that it turns off instead of the Alt+F4 I used to do. I even use an Amazon Echo + Harmony to voice control it with; Alexa, turn PC on/off.
Relay with extended phototransistor

T/Y join of front panel I/O + Relay NC/COM

The relay on top of the PSU in the case


  1. Neat solution, thanks very much for documenting it here :)

  2. Hello, it looks like it's a great idea and very easy to do. I'm about to do this but I don't want to burn my motherboard. Has this worked for anyone else?

    1. You're not going to burn your mobo... very worst you short the PSU, but that's protected all over.
      You can also get power from a USB header on your mobo, but depending on your USB power settings it may not be powered from full off... you have to use a meter to check it's powered while off.
      I've done it on 2 PC, both using USB header bcos it's neater than using the atx plug.

  3. The relay finally arrived from China and it worked well except with my harmony hub.
    ... Is there a way to make this relay learn a new ir command?


    1. I had some difficulty making it learn the IR cmd too. Make sure you're doing the learning process right with another remote, then use the Relay remote moving it back and forth 5-50cm the Harmony will eventually learn it.
      In the +15 months I've been using it, it has been flawless except once the Relay forgot the 2 seconds on cmd, and I took everything apart trying to figure out why it wasn't working, when all I had to do was reset the 2 seconds on cmd. with the original remote.

    2. Finally found the problem..... harmony learned the command correctly BUT, This relay also reacts to the input command on my receiver, apparently they both use the same frequency...

      I will have to find a 5v timer relay module with IR learning.... Talk to you soon.... Thank you for your help.

    3. That would be an issue, depending on the command.
      Which AVR command and brand AVR do you have? Mine is a Marantz, no issues and prior I had a Yamaha also no issues.

    4. Onkyo tx-sr508, the command is input VCR

  4. But it also reacts to power toggle and several other keys on my Onkyo remote..

  5. Update, I had no option but getting the simerec pcs-2 IR learning PC switch. Very easy to install, works like a charm. Although somewhat expensive at $45.

    1. It makes it much neater, and $45 for the convenience I think is worth it.

  6. Great project!

    I order de IR switch in de link "https://www.ebay.com.au/itm/400771981262" this switch works only on 12v not on 5v!
    I order a second one, same issue
    Tip: Order ATX extenter, to save you PSU warrenty link: https://nl.aliexpress.com/item/30cm-24Pin-ATX-Dual-PSU-Power-Extender-Cable-Adapter-Computer-Connector-for-PC-Bitcoin-Mining-Machine/32821124499.html?spm=a2g0s.9042311.0.0.stl4t2

  7. Replies
    1. In the technical information on page 3 : https://www.winddeal.net/image2/tools/30464.rar
      there are 3 versions available for 5, 12 and 24 volts, I have now ordered the 5v and keep you informed.

  8. Yes, it works!
    After I received the 5v module, it worked properly.
    Thank you for your inspiration

  9. To Rayone: you also have the 5v module, as I see in the picture "Relay with extended phototransistor"
    This is different from the picture "poor drawing" ;-) you can see the difference between the 5v and the 12V on the blue switch. please modify the buy link to ebay to a 5v module, so that other people do not make the same mistake as me.Thank you very much

    1. I removed the link bcos now I can only find 12v relays on ebay.

  10. Just to keep the thread alive, I purchased a 5v InfraRed remote also.
    The unit itself works well but learning the Harmony Elite with the supplied remote is troublesome. The Harmony remote eventually learns from the supplied remote, but the harmony hub fails to sync every time for me.

  11. Harms because of mishaps and other significant effects can go hopeless. In these cases, the windshield should be repaired. computer upgrade service

  12. I wanted to thank you for this great read!! I definitely enjoying every little bit of it I have you bookmarked to check out new stuff you post. pc repair Kansas city

  13. Nice post! This is a very nice blog that I will definitively come back to more times this year! Thanks for informative post. Kentique

  14. Wow, What a Excellent post. I really found this to much informatics. It is what i was searching for.I would like to suggest you that please keep sharing such type of info.Thanks laptop repair kansas city