How to avoid the pesky HTC One (M8) lock key at the top, and use a simple swipe instead

How to avoid the pesky HTC One (M8) lock key at the top, and use a simple swipe instead
We have to admit that the larger those phone screens get, the less enthusiastic we get about power/lock keys that are situated on the top of the handset. They are much harder to get to without looking, requiring you to stretch your finger quite a bit to reach them up top, when operating the phone with one hand. That's why we were a bit miffed when we saw that in the new, taller HTC One (M8), the lock key is still placed at the top, asking for even more digit gymnastics.

Granted, HTC introduced the double-tap-to-wake gesture with the One (M8), but locking the display from within the interface still requires you to do some palm yoga. The modding community, however, lives and breathes for such issues, and there is now a much better way to lock your new HTC One (M8), provided that you have a rooted handset, with installed recovery for flashing custom ROMs and mods.

The mod, adapted by the developer flar2, is aptly named Sweep2sleep, and works just as it says on the tin - you can lock the phone by simply swiping right to left over the black notification bar at the top of the display. Here's what you need to do, in order to avoid the pesky lock button at the top of your HTC One (M8):

1. Download the Sweep2sleep mod as a flashable ZIP file; 
2. If you don't have custom recovery installed, you can use the newbie-oriented HTC One (M8) All in One Toolkit by XDA-Devs member hasoon2000. It lets you easily unlock the bootloader, root, and install custom recovery. Bear in mind that, as usual, you will do this at your own risk;
3. Using your recovery method of choice, flash the Sweep2sleep mod on the One (M8);
4. If you have a custom ROM, the mod should load automatically at boot, but if you have stayed with the stock Sense 6.0, you need to add the following module:

insmod /system/lib/modules/s2w_mod.ko

5. If for some reason you wish to remove the Swipe2sleep mod, use the following code in recovery:

adb shell rm /system/lib/modules/s2w_mod.ko /system/etc/init.d/40s2w

That's it, you can now double-tap on the screen to wake the phone up, and simply swipe over the navigation bar right to left with your thumb to lock it back again, without using the uncomfortably-placed power button at the top of the HTC One (M8)

source: flar2 (XDA-Devs)

Related phones

One (M8)
  • Display 5.0" 1080 x 1920 pixels
  • Camera 4 MP / 5 MP front
  • Processor Qualcomm Snapdragon 801, Quad-core, 2300 MHz
  • Storage 32 GB + microSDXC
  • Battery 2600 mAh(20h 3G talk time)



1. papss unregistered

Or you could tap again to turn off?

7. ScottSchneider

Posts: 336; Member since: Dec 06, 2011

"Ok Google" Lock my screen... That must be the one on the "One"..

24. fireblade

Posts: 717; Member since: Dec 27, 2013

there are many apps for turning off the screen.

2. magnanimus

Posts: 565; Member since: Mar 29, 2013

Aren't you still reaching for the top of the phone Either case or am I Missing something?

3. papss unregistered

No you can double tab anywhere on the screen to go into lock mode... Not sure what this article is implying really.

9. Chris.P

Posts: 567; Member since: Jun 27, 2013

Only if you're at the lockscreen.

10. papss unregistered

Maybe its my l1520 I'm thinking of. I'll try the m8 when I get home

4. marlboro

Posts: 94; Member since: Mar 27, 2014

how about the battery life?

6. papss unregistered

Battery life is excellent actually. I was apprehensive at first but its been great..

5. jellmoo

Posts: 2620; Member since: Oct 31, 2011

So instead of hitting the button on the top of the screen, you have to swipe the notification area which is located at the top of the screen? And for this "convenience", all you have to do is void your warranty? Really?

8. AfterShock

Posts: 4147; Member since: Nov 02, 2012

Flar2 is a great Dev. I wonder if he adds the power off key switching on it too, that is a nice option.

11. AfterShock

Posts: 4147; Member since: Nov 02, 2012

I mean to switch off the swipe to wake option. To clarify about power button on/off abilities.

12. papss unregistered

Biggest issue for me IS the power button. Its flush and if you are feeling for it you can't really tell until you push.

13. AfterShock

Posts: 4147; Member since: Nov 02, 2012

I thought they(HTC) were including tap to wake?

14. papss unregistered

They do but not to shut off or to go to sleep unless you are in lock screen already. If it was just a hair higher it wouldn't be a problem

15. AfterShock

Posts: 4147; Member since: Nov 02, 2012

Really? That kind of sucks that it was over looked. Desk usage without having to pick up the phone is stellar to me, not sure about others.

17. papss unregistered

I agree... I use it on my 1520 and love it so when I heard about double tap on the m8 I was excited but its not quite as functional as I would like.. Great phone overall but some short comings too.. I don't mind the camera so much but its not great either

16. zachattack

Posts: 621; Member since: Jul 31, 2013

Wouldn't root my phone for that.... but not being able to lock it while in the phone is annoying. I don't think I want the 5.5 inch G3

18. lallolu

Posts: 732; Member since: Sep 18, 2012

I always use a widget to lock my screen. So much convenient.

19. Onami

Posts: 16; Member since: Mar 29, 2014

How to avoid that: dont buy M8... HTC didn't learn to listen their user complaint, camera, bezel, and top power button @@ I hope they can exist until next and release M9 fixed all problem thay made in M7,M8 ...

20. papss unregistered

Other than camera none of those are deal breakers, unless of course you have baby hands

25. Taters

Posts: 6474; Member since: Jan 28, 2013

I disagree. I don't give a crap about the camera but everything else is a deal breaker. Especially the top button.

26. Onami

Posts: 16; Member since: Mar 29, 2014

That is the way you and your HTC lose the battle... You think it's good enough and people will buy it, but that is your opinion, not me - a user.

21. Gothbeard

Posts: 54; Member since: Jun 28, 2010

Dumb power button IS a deal breaker. HTC failed to listen.

22. Dadler22

Posts: 241; Member since: Dec 11, 2008

Sounds good, except that "knock to on" or "swipe on" requires the touchscreen input to always be on and waiting, which uses moderate levels of battery life.

23. 1ceTr0n

Posts: 549; Member since: May 20, 2012

The Note series don't suffer from this issue *hint, hint*

Latest Stories

This copy is for your personal, non-commercial use only. You can order presentation-ready copies for distribution to your colleagues, clients or customers at or use the Reprints & Permissions tool that appears at the bottom of each web page. Visit for samples and additional information.