Install Nexus Android on Samsung S4 The Android OS that comes with the Samsung S4 has quite a few unwanted extras. The Android OS that comes with the Nexus 5 is quite slim and I prefer its interface.

Is it possible to replace the OS running on the Samsung S4 with the Nexus-flavoured android?
Yes; The Nexus Android is closer to AOSP which is a minimal OS all the other Android distributions are built on. You probably want CM though as it's the most popular pre built ROM for your device.

https://wiki.cyanogenmod.org/w/Jfltexx_Info

Also unlike the Samsung ROM, CM gets security updates every month and unlike Samsung will continue to for older devices like the S2, S3, etc.

https://en.m.wikipedia.org/wiki/AOSP