Chosen Solution

Good evening to all! My iPhone 6 suddenly started acting like if its power button is being pressed (or stuck) when it isn’t. When phisically pressed, it randomly responds, with most of the time not responding. At any moment, without any action from me, shows the turn off slider in the same way that would appear normally if the power button is keep pressed. If I turn it off, then it keeps showing the apple logo repeatedly (bootloop), just as if it were about to start, but it never starts until I plug it to its charger or to my laptop. However, when I plug it to the charger or to the laptop, it behaves normal. The button becomes phisically responsive again and it stops showing the turn off slider. When I disconnect it, it returns to the same odd behavior. Due to this, I tought it could be a software problem, but I have already installed the latest iOS update and it keeps acting odd. It could really be a hardware problem or it is a software problem? Thank you all in advance!

It sounds like you need replacing the power button connecting cable that includes the physical part that clicks when you put pressure..for one reason or another seems to be damaged. You can follow this guide to get yourself an idea if you feel like doing it yourself: iPhone 6 Power Button Cable Assembly Replacement

first I`d check for water damage, clean with isopropynol and a tooth brush is you find any signs, then if its still acting up try a new power button flex(just hang it in) and see if the issue is sorted.