Even with this being the case, older handsets continue to get updated to new versions of Android thanks to custom ROMs. Although these may not be official updates directly from Google, it's still quite impressive as to just how dedicated some developers are to breathing new life into arguably old and outdated devices. Most recently, the folks over at Cyanogen released nightly builds of CyanogenMod 14 for the Google Nexus 4.
CM14 is based off of Android 7.1 Nougat, so the Nexus 4 now has access to all of the latest and greatest that Google's most recent OS update has to offer. Nightly builds do have a tendency to contain various bugs and glitches, but if you've got an old Nexus 4 lying around and are comfortable with the act of loading custom ROMs, you might as well tinker around with it and have some fun.
For those that want to be even more adventurous with the Nexus 4, Cyanogen has also released an experimental build of CM14 for the phone, but this one is likely to be even more unstable than the nightly builds that are also available. And, if you don't own a Nexus 4 but still want to get in on the Android 7.1 action, nightly builds have also be released for the LG G3, LG G Pad 8.3, Sony Xperia M, and more.