How to Enable Google Lens in Google Photos Right Now [Root]

We may earn a commission for purchases made using our links.

Envious of the new Google Pixel 2 and Pixel 2 XL owners? Given the recent display troubles some users have been having, maybe your envy has waned a bit. Still, there are some Pixel exclusive software features that you may really want to try like Google Lens. It’s a pretty neat feature that leverages Google’s machine learning technology to scan images to bring up relevant information. It recognized this Redditor’s particular cat breed, for instance. We have tried, on numerous occasions in the past, to get Google Lens working—though in each case Google quickly shuts down the method. We’re back again with yet another way to enable Google Lens in Google Photos.

What is Google Lens?

Announced at this year’s Google I/O, the feature allows you to point your camera (via Google Assistant) or analyze an existing image (via Google Photos) to provide useful information about what you are looking at. On stage, the company showed off Lens analyzing flowers to show what kind of flower it was, pointing your phone camera at a restaurant to see information like recent reviews, or scanning a WiFi network sticker to connect to a network. It has been compared to Google Goggles by many, but can be though of as its spiritual successor.

According to an APK teardown of Google Photos that we performed a while back, here is what Google Lens is currently capable of:

Identify: Artwork

Barcodes

Books

Buildings

Landmarks

Media covers

Movies

Music albums

Paintings

Places

Points of Interest

Statues

Video games Perform: Add contacts from a business card

Language translation

Look up product information

Open web addresses in your browser

Plant and animal identification

Save dates to your calendar from a poster

Try out Google Lens in Google Photos Right Now

Much like previous methods, we will be tricking the Google Photos application into thinking the phone is a Google Pixel 2. We do this by adding files to /system/etc/sysconfig that are exclusively found on the Google Pixel 2. I confirmed the existence of these files in the factory images of the devices. The files are called pixel_2017.xml and pixel_2017_exclusive.xml and contain the following lines:

pixel_2017.xml <?xml version="1.0" encoding="utf-8"?> <!-- These are configurations that should exist on Google's 2017 and newer Nexus devices. --> <config> <!-- This is meant to be the canonical feature identifying 2017 and newer Nexus devices. --> <feature name="com.google.android.feature.PIXEL_2017_EXPERIENCE" /> </config>

pixel_2017_exclusive.xml <?xml version="1.0" encoding="utf-8"?> <!-- These are configurations that should exist on Google's 2017 devices (and not newer/older) --> <config> <!-- This defines the Photos preload feature for specifically the 2017 Pixel devices. --> <feature name="com.google.android.apps.photos.PIXEL_2017_PRELOAD" /> </config>

Users could previously get away with only adding a file called “nexus.xml” to this directory, but it appears that is no longer working by itself. But with the inclusion of these two files in /system/etc/sysconfig, Google Lens in Google Photos will now work.

So what do you actually do? That’s simple! Follow these steps to enable Google Lens in Google Photos on a rooted Android device (tested on my OnePlus 5 running OxygenOS on Android 7.1 Nougat):

How to Enable Google Lens

Download the flashable zip file found in this thread, made by XDA Member ZeevoX Reboot into TWRP Recovery Flash the zip file in recovery Boot back into Android and open up Google Photos

According to ZeevoX, you shouldn’t even need to clear app data in Google Photos! He made a short screen recording you can view here that shows off activating Google Lens. Note that although he posted this in the OnePlus 3 forum, there’s nothing specific or unique about this modification to the OnePlus 3 so it should work on any rooted Android device!

Give Google Lens a try right now and let us know your thoughts below! Google could very easily patch this method by updating Google Photos in the next few hours or days, but given that Pixel 2 smartphones are already on the market and the Xposed Framework for Android Nougat is out, it’ll be hard for them to keep playing this cat-and-mouse game with us.