Huawei P40 Pro: how to install Google Services

Translation: Eva Francis

The Huawei P40 Pro doesn’t come with Google Services. Want to install them? Follow these 10 steps and you’ll have Play Store and YouTube back on your phone.

It’s possible. Google Mobile Services (GMS) can be installed on the Huawei P40 Pro. It’s not as easy as it used to be, but it’s comparable. The following guide shows you how to do the following:

  • restore a backup
  • assign yourself grant administrator rights
  • install the apps and services
  • put apps into a pseudo-stable state
  • suppress a warning

I strongly recommend that you set the phone to English – at least for a short time. This will make it easier to follow this tutorial, as some options have different names in English and German.

Here are a few remarks about the hack:

Attention: drastic changes

This hack makes radical changes to the operating system – and changes the system in a way that’s not intended. There is a safety risk, in theory. But since the steps are the same as for the Mate 30 Pro – with a few extra tricks – I’m pretty sure nothing bad will happen.

We give our Huawei P40 Pros administrator rights. This makes it possible to make changes on a level that’s usually not possible. The problem lies under the App Layer. For a detailed explanation (in German) of the problem, check out this article:

  • Background information

    Huawei ohne Google Services: Ein Blick auf das Mate 30 und die Zukunft Androids

    by Dominik Bärlocher

An Android distribution with Google Services – which is far more than the App Store and Google Maps – looks like this:

The Mobile Services are provided by Google
The Mobile Services are provided by Google

The middle level is where the services are stored. It’s a series of program interfaces that allow you to interact with Google's apps. The services are provided by Google and are used by app developers. It makes sure they don’t have to program every single connection into their apps. Instead, they tell the app: «App, use the service». That’s all it takes. But if the service is missing, the app will return an error or close down. That's the problem with Huawei phones.

Google Mobile Services aren’t allowed.
Google Mobile Services aren’t allowed.

Huawei is solving the problem in the long term by building Huawei Mobile Services (HMS), which is the same as Google Mobile Services (GMS). However, the apps aren’t yet compatible with HMS, as they explicitly require GMS.

Since HMS aren’t yet ready for everyday use and the apps offered in Huawei’s App Gallery – charmingly referred to as «App Gary» by Huawei’s Mobile CEO Richard Yu – are still quite limited, many users want to upgrade the mobile services. In the end, GMS and HMS run in parallel.

Huawei Mobile Services and Google Mobile Services run in parallel
Huawei Mobile Services and Google Mobile Services run in parallel

Usually, you cannot access the services, as there’s no reason to do so. Interacting with the top level of the apps is enough. But not today.

Today, we’re letting a secure system know that we want to dig into and tinker with its inner workings.

The setup

For this hack, you need a little more hardware than for the previous version: you need a Windows computer. I'm sure there’s a way to make it work on Mac, too, but I can only confirm that it works with Windows at this moment.

  • a Windows computer
  • a USB cable to connect the P40 Pro to your computer
  • a USB memory that you can connect to the P40 Pro
  • a Huawei P40 Pro

Any Windows device will do, but I’m taking a Huawei laptop just for fun. But and other Windows device is also fine. The same goes for the USB stick: I used my Sandisk Extreme, which I usually use to transfer video files, but any USB storage device you can connect to the phone will do the job.

Huawei P40 Pro (5G) + MediaPad M5 Lite (256 GB, Frosted Silver, 6.58 ", Hybrid Dual SIM, 50 Mpx, 5G)
Mobile phones

Huawei P40 Pro (5G) + MediaPad M5 Lite

256 GB, Frosted Silver, 6.58 ", Hybrid Dual SIM, 50 Mpx, 5G

Huawei P40 Pro (256 GB, Silver Frost, 6.58 ", Hybrid Dual SIM + eSIM, 50 Mpx, 5G)
Mobile phones

Huawei P40 Pro

256 GB, Silver Frost, 6.58 ", Hybrid Dual SIM + eSIM, 50 Mpx, 5G

Huawei MateBook D15 (15.60 ", AMD Ryzen 5 3500U, 8 GB, 256 GB, CH)

Huawei MateBook D15

15.60 ", AMD Ryzen 5 3500U, 8 GB, 256 GB, CH

SanDisk Ultra Dual Drive (128 GB, USB C, USB Type A, USB 3.1)
USB memory sticks

SanDisk Ultra Dual Drive

128 GB, USB C, USB Type A, USB 3.1

  • Guide

    SanDisk Extreme Portable: Unser liebster Freund auf Reisen

    by Dominik Bärlocher

Now, let’s get started.

1. Preparing your phone

In order to access your phone later while working with the PC, you need to activate USB debugging. For this purpose, we activate the Developer Options:

  1. Go to the settings of your P40 Pro.
  2. Scroll down to «About Phone».
  3. Click «Build Number» seven times fast.
  4. Enter your PIN if you have already set one.

This makes you a developer on your phone. Let's activate the one developer option we need.

  1. Go to the settings of your P40 Pro.
  2. Scroll down to «System and Updates».
  3. Press «Developer Options».
  4. Enable «USB Debugging».

2. Preparing the USB storage device

In order to install things, we have to work with external memory. We need to restore a backup and, in our case, this is only possible using external storage.

  1. Download the following ZIP to your Windows computer:
  2. Extract the ZIP into a separate folder.
  3. Copy the Huawei folder to your USB memory.
  4. Copy the apk folder to your USB device.

Now connect the USB stick to the Huawei P40 Pro.

3. Restoring the backup

Now, we’re going to restore a backup. It's all about recovering a version of the app LZPlay with some settings and upgrading an app called Icebox. It's done quickly, but what we do here is giving a lot of rights to an app of unknown origin. This has to be the case, as this is exactly what administrator rights do. We use the software to give ourselves the rights to do and change everything on the phone. This is unusual and risky, but experience with the Mate 30 Pro shows that there’s no acute danger from LZPlay itself. Even after almost half a year, the Mate 30 Pro hasn't had any suspicious functionality or generated any strange traffic.

Don’t agree? Let me know by commenting below. Concerns are important, as these things shouldn’t happen without questioning. Just because I and the rest of the hacker community say that this is harmless «as far as we can tell», it doesn't mean it actually is. It just means that us hackers are pretty sure you won't do any permanent damage.

  1. Go to the settings.
  2. Scroll down to «System and Updates».
  3. Click «Backup and Restore».
  4. Select «Data Backup».
  5. Go to «External memory».
  6. Select the USB memory.

The system displays a backup dated 31 March 2020 at 06:35 a.m. The password is:


We've now completed the complex part of the operation.

4. Returning to the purple G

If you've done everything right so far, you'll have two apps on your home screen: an app called Icebox and an app with a Chinese name, generally called LZPlay.

The Chinese app with the purple G
The Chinese app with the purple G
  1. Open LZPlay.
  2. Press «Activate».
  3. Ignore the second screen and close the app.

The next part might spark this reaction from those concerned about security:

That's a sensible reaction. In the current political and economic situation, finding a safe way to get Google onto your Huawei device is impossible. There’s no absolute certainty that you can follow this guide without worrying. But: I’m not going to tell you what to do and what not to so. That’s up to you to decide. I'll show you how to do it, but you have to make your own decisions about your technology. But in the context of this guide I can say that the LZPlay app does exactly what it claims to do and nothing else. Lots of things, not just LZPlay, remain slightly risk when you dig so deep into your phone's system.

If you're interested in learning more, read the screen. This is exactly what having admin rights mean. Be aware that most users who express security concerns are making a legitimate point, but might have no experience at all. The experience with LZPlay, to date, is unanimous: «It’s safe as far as we can judge».

5. Installing apps

There’s a folder called «apk» on the USB storage. There are four apps in it. Install them in the order of the file names: first (1), then (2) and so on.

  1. Open the «Files» app.
  2. Click «Categories».
  3. Select your USB memory.
  4. Go to the folder «apk».
  5. Click on the apps and install them.
  6. But don’t open the apps, always click on «Done».

From now on, a warning will appear. It says that your device is not «Play Protect Certified» and that this should be fixed. Yes, that’s true, but if you choose to perform this hack, you take the conscious decision to live with this. You’ll have to swipe away the warning for the rest of the tutorial. We’ll fix it at the very end. Until then, I'm afraid you're going to have to bear it.

6. Icebox and USB

You don't need the USB stick anymore. Open the App Icebox on the phone. There's a tutorial that you can skip with «Cancel» – unless you’re actually interested in them.

We’re now putting the Google services into a so-called pseudo-stable state for a moment. This means we’re freezing the app so that it remains in a certain state while we work around it. Meanwhile, this relies on the system and the app saying «Sure, sure, that’s normal» for a moment, although everything isn’t okay quite yet.

  1. Plug your phone into your PC.
  2. Select «Transfer Files» as connection mode on the phone.
  3. There should now be a warning about «Allowing USB Debugging».
  4. Check «always allow» and then «OK».
  5. If the warning doesn’t appear, reactivate USB debugging. As you did above.

On the PC, do the following:

  1. In the folder in which you initially extracted the data, go to the folder «ADB».
  2. Double click on «Adb 1.4.3.exe».
  3. Install the program. It’s the Android Developer Bridge (adb), which allows you to communicate with the phone via terminal.
  4. Run the adb when you’re asked to at the end of the installation process.

A black console window opens.

Let's quickly check if the device is recognised correctly. Enter the following command line.:

adb devices

If that worked, the window will show something like this:

C:\Program Files (x86)\Minimal ADB and Fastboot>adb devices
List of devices attached
K5J0225308800836 device

We can work with that. Enter the following:

adb shell sh /sdcard/Android/data/com.catchingnow.icebox/files/

We’ll start the Icebox as a developer. This becomes relevant in a second, as we cannot simply force the pseudo-stable state on the app level. The script has to run on another level.

If it worked, then the terminal says «success».

Without unplugging the phone, go to the Icebox app on the P40 Pro.

  1. Go to the «System» tab.
  2. Search for «Google Services Framework». Attention: the name might be different depending on the language setting. That's why I advised above to set your phone to English.
  3. Click «Google Services Framework» once.
  4. An overlay window appears at the bottom.
  5. Click «Freeze».

The app is now frozen.

7. Phone, forget Google for a second

Now we’re letting the P40 Pro forget that it ever had anything to do with Google. For a while. One of the four installed apps looks quite basic and is called «Google Account Manager». That’s the one we need right now.

  1. Open «Google Account Manager».
  2. Ignore the warning about older version, just click «OK».
  3. Clear the cache.
  4. Delete the data.

8. Google, here we come

We’re slowly coming to the end.

  1. Open the Play Store on the phone.
  2. Log in.

We’re now ending this hacking operation in a neat and tidy way.

  1. Open the Icebox again.
  2. Unfreeze the Google Framework Services.
  3. Uninstall the unwanted apps if you like. Since we installed the apps via Sideload, they don’t update in the background. This means the app will never change the way it works and will remain as it is today.

9. Go away, Play Protect

Finally, let’s get to the warning that’s surely been annoying you for a few minutes now. It's easy to rid of it, but it takes a while. Any app that works with Play Protect Certification, i.e. all Google Apps, will work fine, but the certification will fail. Of course, your phone doesn’t fail to tell you this at every opportunity. On every app. That's why we have to disable it for each and every app.

When this warning appears:

  1. Drag your notification tray down.
  2. Swipe the warning carefully and slowly in one direction until you see the cog wheel.
  3. Click «More Settings».
  4. Go to «Google Play Services Availability».
  5. Deactivate the option.

10. Registering your phone as an exception

In the hope that Google will show some mercy and turn off the play protect warnings, we can register our device as an exception. This doesn't work as well for every model, but it’s definitely no bad idea.

  1. Install the app Device ID on your phone.
  2. Run it.
  3. On your PC, go to
  4. Enter the value under in the field on the website under «Google Service Framework».

The work is now complete. Do all apps work? Yes, no, maybe. Remember, Google Services are still not supposed to be on a Huawei phone.

And that’s it for today. You can switch your phone back to German, French, Italian or Bahasa and use it the way you want. Enjoy!

102 people like this article

User Avatar
User Avatar

Journalist. Author. Hacker. A storyteller searching for boundaries, secrets and taboos – putting the world to paper. Not because I can but because I can’t not.

Follow topics and stay updated on your areas of interest

These articles might also interest you

  • Skeleton Loader

    Skeleton Loader

  • Skeleton Loader

    Skeleton Loader

  • Skeleton Loader

    Skeleton Loader