If wifi and use a common shared "receiver" plugged to USB port, maybe the receiver is failing.
So recently my Keyboard and mouse have stopped functioning properly. By that I mean that my keyboard will not type anything, somehow the caps lock still works, and my mouse doesn't work in terms that when i click links online it'll download the link, or when i right click I can't access the right click options because it automatically clicks out. I have tried everything. I factory reset my PC, because I thought some application caused it. It still happened after. A Common thing that I saw on the internet is enabling filter keys in keyboard settings but that didn't work. I then thought that It may be a motherboard issue or that maybe my USB hubs didn't work, so I went ahead and upgraded my outdated processor and motherboard, BUT MY MOUSE AND KEYBOARD STILL DON'T WORK. I have updated their drivers, uninstalled my keyboard and mouse and reinstalled. I have tried everything on the internet, but I still have that issue. It is really frustrating because they will randomly work and stop working. My guess now is that maybe my power supply is dying, or it isn't creating enough power for it to get to the USB ports. Does anyone have a solution on what it may be?

Chowhound
Comic Vine
GameFAQs
GameSpot
Giant Bomb
TechRepublic