Easy guide to root Android L installed on the Nexus 5. Android L has been already published on Google’s official developer site and every Nexus 5 user can install it and get a good idea how the next version of Android is.
However, this release isn’t for everyday consumers. It is a Developer Preview for developers to optimize their apps for Android L but all those who want to install it are free to do so.
Even though Android L Developer Preview has been released just a few days ago, the popular developer, Chainfire, which is known to root almost every Android device, has also released a fix to the current SuperSU app in order to work with Android L Developer Preview image.
Before rooting your Nexus 5, make sure to backup everything on your phone. Also your Nexus 5 should have more than 50% battery left. One thing to note is that you must install a custom recovery in order to install the file. In this case, a custom recovery like TWRP is recommended.
To root the Nexus 5 with Android L Developer Preview build, download SuperSU here and boot file here. Then boot your Nexus 5 into recovery mode and flash both of the downloaded files. Once you have flashed both, reboot your phone. Now you should have full root access.