Google Apps keep reinstalling/ reactivating

That seems to have done the trick! Thank you!

1 Like

Edit: Nevermind, just got it with the additional command --user 0 mentiond by @solanum

I tried to uninstall the nasty google stuff on my fairphone 3 using this method, but everytime I type the command pm uninstall *package name*, I get the readout Failure [DELETE_FAILED_INTERNAL_ERROR].
I tried this with several apps and a search on ecosia didn’t help me either. So I have no idea what to do now.

This is important. Some Apps will not work!

If you uninstall WebView and later perhaps want to try e.g. the Play Store nonetheless or just add a Google account in the settings, you will just get a black screen because WebView is missing.
Without the WebView APK to install it again you can use APKMirror …

https://www.apkmirror.com/?post_type=app_release&searchtype=apk&s=com.google.android.webview

… choose the latest “Android System WebView” which is not labeled “beta”, for the correct variant choose Architecture “arm64-v8a + armeabi-v7a” and Minimum Version “Android 5.0+” (currently, as long as “Android 10.0+” doesn’t fit the Fairphone 3).

Some apps, especially some Google stuff, may refuse deinstallation if they are defined as app for device management.
Have a look at <Security & Location >> Apps for device management> (frei übersetzt, deutsch: Sicherheit & Standort >> Apps zur Geräteverwaltung)
Disable them there and repeat the adb command.

Some time ago I had made a little script for a Huawei Mate 9 to delete some Google and other apps. I have modified it to run against my FP3. It contains the -k flag in every pm command. Thanks @Roboe for the hint about it. I’ll correct and test it later.

For reference I attach it here:

##########

#!/bin/bash
adb devices

#adb shell pm list packages

#google
adb shell pm uninstall -k --user 0 com.google.android.onetimeinitializer
adb shell pm uninstall -k --user 0 com.google.android.apps.photos
adb shell pm uninstall -k --user 0 com.android.hotwordenrollment.okgoogle
adb shell pm uninstall -k --user 0 com.android.hotwordenrollment.xgoogle
adb shell pm uninstall -k --user 0 com.google.android.googlequicksearchbox
adb shell pm uninstall -k --user 0 com.google.android.music
adb shell pm uninstall -k --user 0 com.google.android.videos
adb shell pm uninstall -k --user 0 com.google.android.feedback
adb shell pm uninstall -k --user 0 com.google.android.backuptransport
adb shell pm uninstall -k --user 0 com.google.android.gm
adb shell pm uninstall -k --user 0 com.google.android.gms
adb shell pm uninstall -k --user 0 com.google.android.gmsintegration
adb shell pm uninstall -k --user 0 com.google.android.apps.restore
adb shell pm uninstall -k --user 0 com.google.android.gms.policy_sidecar_aps
adb shell pm uninstall -k --user 0 com.google.android.tag
adb shell pm uninstall -k --user 0 com.google.android.gsf
adb shell pm uninstall -k --user 0 com.google.android.gsf.login
adb shell pm uninstall -k --user 0 com.android.vending
adb shell pm uninstall -k --user 0 com.google.android.apps.tachyon
adb shell pm uninstall -k --user 0 com.google.android.apps.maps
adb shell pm uninstall -k --user 0 com.google.android.apps.docs
adb shell pm uninstall -k --user 0 com.google.android.syncadapters.contacts
adb shell pm uninstall -k --user 0 com.google.android.syncadapters.calendar
adb shell pm uninstall -k --user 0 com.google.android.ext.services
adb shell pm uninstall -k --user 0 com.google.android.ext.shared
adb shell pm uninstall -k --user 0 com.google.android.youtube
adb shell pm uninstall -k --user 0 com.google.android.apps.messaging
adb shell pm uninstall -k --user 0 com.google.android.calendar
adb shell pm uninstall -k --user 0 com.google.android.contacts

#partner
adb shell pm uninstall -k --user 0 com.android.partnerbrowsercustomizations.tmobile
adb shell pm uninstall -k --user 0 com.google.android.partnersetup
adb shell pm uninstall -k --user 0 com.android.providers.partnerbookmarks

#bloat
#adb shell pm uninstall -k --user 0 com.android.chrome
adb shell pm uninstall -k --user 0 com.example.android.notepad
adb shell pm uninstall -k --user 0 com.example.android.notepad
adb shell pm uninstall -k --user 0 com.android.apps.tag

##########

After letting it run, the following preinstalled apps didn’t work anymore:

messaging
calendar
contacts

I added them to the script and substituted them with free alternatives from F-Droid.
Use it at your own risk. Feel free to modify it :wink:

7 Likes

@Stefan
Thank you for putting the script part into shape.

@ All
If your’re willing to try it out please be careful.
I have found that the Setting “System > Systemupdate” had vanished. It could be something in the script but not necessarily. I have resetted my FP3 and now it’s back. Have to investigate …

3 Likes

I have cleaned up a bit and added some comments.
The System-Updater works again. Without com.google.android.gms and com.google.android.gsf it doesn’t.

Please note, that in case of an error every uninstalled package can be reinstalled by issuing the command “adb shell cmd package install-existing <package name>
No reset necessary :slightly_smiling_face:

#!/bin/bash

adb devices
#adb shell pm list packages

#google
adb shell pm uninstall -k --user 0 com.google.android.onetimeinitializer
adb shell pm uninstall -k --user 0 com.google.android.apps.photos
adb shell pm uninstall -k --user 0 com.google.android.googlequicksearchbox
adb shell pm uninstall -k --user 0 com.google.android.music
adb shell pm uninstall -k --user 0 com.google.android.videos
adb shell pm uninstall -k --user 0 com.google.android.feedback
adb shell pm uninstall -k --user 0 com.google.android.backuptransport
adb shell pm uninstall -k --user 0 com.google.android.gm
#adb shell pm uninstall -k --user 0 com.google.android.gms
#com.google.android.gms seems to be crucial for the FP3 System Updater to work
adb shell pm uninstall -k --user 0 com.google.android.gmsintegration
adb shell pm uninstall -k --user 0 com.google.android.apps.restore
adb shell pm uninstall -k --user 0 com.google.android.gms.policy_sidecar_aps
adb shell pm uninstall -k --user 0 com.google.android.tag
#adb shell pm uninstall -k --user 0 com.google.android.gsf
#com.google.android.gsf seems to be crucial for the FP3 System Updater to work
adb shell pm uninstall -k --user 0 com.android.vending
adb shell pm uninstall -k --user 0 com.google.android.apps.tachyon
adb shell pm uninstall -k --user 0 com.google.android.apps.maps
adb shell pm uninstall -k --user 0 com.google.android.apps.docs
adb shell pm uninstall -k --user 0 com.google.android.syncadapters.contacts
adb shell pm uninstall -k --user 0 com.google.android.ext.services
adb shell pm uninstall -k --user 0 com.google.android.ext.shared
adb shell pm uninstall -k --user 0 com.google.android.youtube
adb shell pm uninstall -k --user 0 com.google.android.apps.messaging
adb shell pm uninstall -k --user 0 com.google.android.calendar
adb shell pm uninstall -k --user 0 com.google.android.contacts
adb shell pm uninstall -k --user 0 com.google.android.dialer

#partner
adb shell pm uninstall -k --user 0 com.google.android.partnersetup
adb shell pm uninstall -k --user 0 com.android.providers.partnerbookmarks

#To reinstall the package simply use "adb shell cmd package install-existing <package name>" in ADB.
#Example: adb shell cmd package install-existing com.google.android.gms

6 Likes

Thanks a lot! I did it this way, but now unfortunately I can’t make or receive phone calls. I have installed Simple Contacts pro and Emerald Dialer. When I try to make a phone call, I get an option to “Complete action using - Phone or Dialer”, but nothing happens when I select either of those. When someone calls me, I only hear the ringtone but no screen pops up, and then I only see the number as a missed call notification. What am I missing?

EDIT: figured it out. Had to reinstall Dialer.

6 Likes

Many thanks, all, for this thread! My FP2 is literally falling apart, so I could not wait for a free OS for FP3, as I had initially planned to do. So this is the next best thing, I think, and it worked like a charm!

3 Likes

In newer Android versions, The Dialer app needs to provide In Call UI as well as the UI to accept a call on the lock screen. The Emerald Dialer doesn’t do that yet, although that’s apparently to-be-added feature.
( See Is there any alternative to the default Dialer app - that works on FP3? )
One option seems to be the dialer app from lineage OS which is linked in that thread.

4 Likes

would it make sense to also get rid of com.qualcomm.qti.qms.service.telemetry ? This system app regularky keeps wanting to talk home to the component manufacturer (via cloudfront ) according to NetGuard
(Interface name is “Qualcomm Mobile Security” )

2 Likes

com.qualcomm.qti.qms.service.telemetry

Not sure, trying it out now.

$ adb shell pm list packages | grep telemetry

Returned only that one.

$ adb shell pm list packages | grep qualcomm

Returned a while lot more.

I haven’t come across any negative aspect of it being disabled on my phone =)

3 Likes

In addition to @s99h’s list I uninstalled the following packages.
So far I did not encounter any problems.

#google phone app & gboard
#see note_1
pm uninstall --user 0 com.google.android.dialer
pm uninstall --user 0 google.android.inputmethod.latin

#standard launcher
#see note_2
pm uninstall --user 0 com.android.launcher3

pm uninstall --user 0 com.android.facelock
pm uninstall --user 0 com.android.protips
pm uninstall --user 0 com.google.android.apps.work.oobconfig
pm uninstall --user 0 com.google.android.tts
pm uninstall --user 0 com.google.android.marvin.talkback

note_1
Before uninstalling dialer and gboard you should read @corvuscorax’s thread “Is there any alternative to the default Dialer app - that works on FP3?

note_2
com.android.launcher3 seems to provide the “recent apps” ui for some other launchers. Disableing it just brings back the classic vertical design without any other consequences it seems.

2 Likes

What I’m wondering: Are all of these apps collecting data? For example, the TTS (text-to-speech) provider doesn’t need internet, right? So it doesn’t send text to a server, if I’m not mistaken.

2 Likes

That is the great mystery of this thread.

There are different interests at play. Some people want to replace proprietary software, others software which leaks data, while others have a focus on anything Google specific.

There’s not an analysis shared of what all these applications do. It is of course possible to do some search query, but a lot of work (which not everyone wants to replicate).

So I recommend other people to log what they’ve done, and share their findings, with references. Don’t be shy :slight_smile:

As for your specific example. TTS works locally. It is speech to text which FAMAG do remotely (even though I would argue they don’t need to).

2 Likes

All right, here’s my list:

REMOVED
com.google.android.music
com.google.android.youtube
com.google.android.apps.photos
com.google.android.onetimeinitializer
com.google.android.googlequicksearchbox
com.google.android.feedback
com.google.android.backuptransport
com.google.android.gm
com.google.android.gmsintegration
com.google.android.apps.restore
com.google.android.gms.policy_sidecar_aps
com.google.android.tag
com.google.android.apps.tachyon
com.google.android.apps.maps
com.google.android.apps.docs
com.google.android.syncadapters.contacts
com.google.android.ext.services
com.google.android.ext.shared
com.google.android.partnersetup
com.google.android.videos
com.google.android.inputmethod.latin
com.google.android.configupdater
com.google.android.setupwizard
com.google.android.calendar
com.google.android.apps.wellbeing
com.google.android.apps.work.oobconfig
com.google.android.tts
com.google.android.marvin.talkback
com.android.vending
com.com.android.chrome

STILL THERE
com.google.android.apps.messaging
com.google.android.deskclock
com.google.android.dialer
com.google.android.webview
com.google.android.contacts
com.google.android.calculator
com.google.android.packageinstaller
com.google.android.gms
com.google.android.gsf
com.google.android.ims
com.google.android.printservice.recommendation

I guess I could also get rid of messaging, dialer, contacts, calculator, and printservice, but what the heck.

Also, this site was very helpful to me: Package Index  |  Google Play services  |  Google for Developers

4 Likes

I pretty much ungoogled my FP3 to the max. This is all that’s left:

$ adb shell pm list packages|grep google
package:com.google.android.dialer
package:com.google.android.webview
package:com.google.android.packageinstaller
package:com.google.android.inputmethod.latin

Sadly i was not able to replace the dialer. (Missing call overlay…). It’s definitely trying to call home… I use NetGuard in blacklist mode, blocking all system apps. But you can’t force android to use VPN-Only due to some bug or limitation… A real firewall would be better, but requires root access…

idk if you can replace webview somehow, but apps like nextcloud didn’t work without it.
com.google.android.inputmethod.latin is gboard afaik. I removed it & couldn’t log back in after reboot, because user apps get loaded AFTER the first login… RIP

I replaced all other apps with free alternatives from F-Droid. :kissing_heart:

To get rid of gms/google play services i needed to disable “google protection”-something and the “find my device”-“feature”. After that i could also disable the service via settings GUI.

I also disabled “Automatically install updates on boot” in the debug menu. IDK if it changes anything, but i thought it might prevent reinstallation of whatever.

Ony real bug so far: Signal wouldn’t work, because of missing gms. Normally the client should fall back to websockets, but i guess we need a clean OS for that.

To replace the dialer see this topic here … Is there any alternative to the default Dialer app - that works on FP3?
Works for me.

Yes, I noticed Android System WebView seems important, too. Uninstalling it will break stuff.

Install a different keyboard like Simple Keyboard | F-Droid - Free and Open Source Android App Repository, and then use a PIN instead of a password, and unlocking the phone should work fine with Gboard uninstalled, as the keyboard isn’t used for PINs.
Works for me.

1 Like

Here’s my current take …
I try to walk a line between de-Google-ing the phone while keeping the basic Google Mobile Services (GMS, for OTA updates of the OS and some Play Store Apps I still have as APKs for installing) and the Play Store itself (for updates of remaining Google components) from breaking, even if I try not to use my Google account for now.

I’m not a big fan of installing downloaded APKs from some website without an automatic update possibility which stores like e.g. F-Droid provide, but it seems this will be necessary for now in some cases if I don’t want to compromise too much.


Replacement Apps

Calculator: Arity from F-Droid
(I tried Calculator from F-Droid, too, but it’s really basic. When I seldomly need a calculator, I want to have some advanced stuff. I didn’t try Simple Calculator from F-Droid, because it looked pretty basic on the screenshots, too.)

Calendar: Simple Calendar Pro from F-Droid
(I don’t work much with the calendar, I just sync my few calendar events from Thunderbird to it … I tried Etar from F-Droid, too, and it would work for me as well.)

Camera: Google Camera with HDR+, Nightsight etc. (Xiaomi Poco F1 port) from XDA
(I kept the original Camera App, too, for the moment … can’t decide just now whether to omit it or not.
A well-known and widely used non-Google camera App would be Open Camera from F-Droid.)

Clock: Simple Clock from F-Droid

Contacts: Contacts 1.7.31 by LineageOS from APKMirror
(I tried Simple Contacts from F-Droid, but it can’t put shortcuts of contacts to the home screen, and I absolutely want to have that. Furthermore, one out of two times I tried it, Simple Contacts couldn’t see my contacts when Dialer and LineageOS Contacts could … weird.)

Dialer: Lineage OS Phone 19.0 by LineageOS (Variant: September 21, 2018) from APKMirror
(As Emerald Dialer from F-Droid seemingly doesn’t cut it yet.)

Files: Ghost Commander or Amaze from F-Droid
(There’s still a use case for Files, though.)

Gboard: Simple Keyboard from F-Droid
(Attention! This will not work with a password as unlocking method, use a PIN instead.)

Gmail: Email 9 by LineageOS from APKMirror
(I tried SimpleEmail and FairEmail from F-Droid, both pretty similar K9 forks, but I didn’t like them.)

Google Chrome: Fennec F-Droid from … well … F-Droid

Google Maps: OsmAnd+ from F-Droid
(In case of need Google Maps has a usable website.)

Google Play Store: Aurora Store from F-Droid
(I deactivated the Play Store since Aurora got anonymous login to the Play Store back.)

Launcher: Lawnchair from F-Droid
(I tried Trebuchet from XDA, too, which would work for me, too, but with F-Droid there’s at least a way for automatic updates, even if there are none in sight in this case for now.)

Messages: QKSMS from F-Droid

Music: VLC from F-Droid

Photos: Simple Gallery Pro from F-Droid

Videos: VLC from F-Droid

YouTube: Has a usable website.

YouTube Music : Don’t need it. (Was installed with OS Build number 8901.2.A.0101.20191115)


Mentions for convenience

Simply Solid from F-Droid
(Apparently Android by default has no way of setting a plain colour as background for home and lock screen, it wants to have a picture. If you just want to have a plain colour, Simply Solid saves you from having to make a picture of a plain colour yourself.)

Your local weather from F-Droid
(As far as I’ve seen, the original weather Widget was part of the stock launcher. If you want to have some Widget choices for your weather, here’s an F-Droid App that gives you some. This works especially well if you have your own OpenWeatherMap API key.
There are other weather Apps on F-Droid, too.)


Still there

com.android.documentsui … Files (see above)
com.android.fpcamera3 … Camera (not yet uninstalled)
com.android.vending … Play Store (on purpose, see top)
com.google.android.apps.work.oobconfig … What does this do? Android Work Profiles perhaps?
com.google.android.configupdaterauto updates certificates, firewall configuration, time zone info
com.google.android.gms … Google Mobile Services, important for Apps relying on them and for receiving SMS Edit by @Stefan: Not true (QKSMS and Silence work), see here.
com.google.android.gsf … Google Services Framework, important for Apps relying on it and for receiving SMS Edit by @Stefan: Not true (QKSMS and Silence work), see here.
com.google.android.ims … Carrier Services
com.google.android.marvin.talkback … Android Accessibility Suite
com.google.android.packageinstaller … sounds harmless
com.google.android.printservice.recommendation … What does this do?
com.google.android.tag … Google Tag Manager, may be used by Apps
com.google.android.tts … Text-To-Speech engine, missing TTS may be inconvenient with Apps used for navigation, and there’s no real FOSS alternative right now. Let’s believe TTS conversion is being done locally.
com.google.android.webview … Android System WebView, handle with care.


Uninstalled via adb shell pm uninstall --user 0 packagename
(and watch out for App updates which might still need to get uninstalled)

com.android.chrome … Google Chrome
com.android.launcher3 … Stock launcher
com.android.providers.partnerbookmarkssounds useless
com.google.android.apps.docs … Google Drive
com.google.android.apps.maps … Google Maps
com.google.android.apps.messaging … Messages
com.google.android.apps.photos … Photos
com.google.android.apps.restore … sounds useless when I backup and sync locally
com.google.android.apps.tachyon … Google Duo
com.google.android.apps.wellbeing … Digital Wellbeing
com.google.android.apps.youtube.music … YouTube Music
com.google.android.backuptransportImplementation for the Android Backup Service, providing key/value cloud storage for apps.
com.google.android.calculator … Calculator
com.google.android.calendar … Calendar
com.google.android.contacts … Contacts
com.google.android.deskclock … Clock
com.google.android.dialer … Dialer
com.google.android.ext.services … Android Services Library, sorts notifications by “importance” based on things like freshness, app type (IM apps come first), and by contact.
com.google.android.ext.shared … Android Shared Library, what does this do?
com.google.android.feedback … I don’t give any, at least not willingly :slight_smile: .
com.google.android.gm … Gmail
com.google.android.gms.policy_sidecar_aps… What does this do?
com.google.android.gmsintegration … Google Sample Home Screen
com.google.android.googlequicksearchbox … “Google”, literally
com.google.android.inputmethod.latin … Gboard
com.google.android.music … Music
com.google.android.onetimeinitializerThis is the setup wizard when you first run your phone.
com.google.android.partnersetup … What does this do?
com.google.android.setupwizardsetup wizard from Google
com.google.android.syncadapters.contacts … Google Contacts Sync
com.google.android.videos … Videos
com.google.android.youtube … Youtube


Some complementary settings

I’ll just list some settings here for reference without much testing yet. Maybe I’ll retract some later when I realize they break stuff.

Some default values of settings might be clearly useful under certain circumstances, so please make up your own mind at every step you take.

First time setup

Make some sensible choices about Google’s immediate involvement when you first start the phone (or after a factory reset) concerning location, backup, sending usage data etc. … and don’t add a Google account.
Skip logging in to a Wi-Fi network and immediately disable Mobile data in the quick settings once you reach the home screen, until you first have initially checked through the Settings tree whether you can prevent some Google “damage” already.

Settings

  • Accounts (I know it’s not on top in reality, but it’s important.):
    Don’t add a Google account here (or by other means like the first time setup assistant or else) if you don’t really have to.
    If you really have to, first turn off “Automatically sync data” here, then add the account and perhaps try to minimize syncing in its settings, then turn on “Automatically sync data” again, then check the settings of the Google account again to be sure.

  • Network & Internet

    • Wi-Fi
      • Wi-Fi preferences
        • Advanced
          • Network rating provider: None (instead of Google)
  • Apps & notifications

    • Default apps: (Make sure non-Google replacement Apps are set here, if any.)
      • Opening links
        • Instant Apps: Off
    • App permissions
      • Body sensors
        • Google Play services: Off
      • Calendar
        • Google Play services: Off
      • Call logs
        • Google Play services: Off
      • Camera
        • Google Play services: Off
      • Contacts
        • Google Play services: Off
      • Microphone
        • Google Play services: Off
      • Additional permissions: (Nothing interesting set here for me, but you might want to check.)
  • Security & location

    • Google Play Protect
      • (cog wheel top right)
        • Scan device for security threats: Off
    • Find My Device: Off
    • Location
      • Google Location Accuracy
        • Improve Location Accuracy: (Turn this off to make it harder for Google to know which Wi-Fi and mobile networks you hang around. Location would purely rely on GPS then and might be more inaccurate/ unavailable e.g. indoors.)
      • Google Location Sharing: (I don’t know what’s in here without a Google account.)
      • Advanced
        • Scanning
          • Wi-Fi scanning / Bluetooth scanning: (I don’t know whether they are Google-related, but judging by their description it seemed sensible to me to turn them off.)
    • Advanced
      • Trust agents
        • Smart Lock (Google): Off
  • System

    • Languages & input
      • Virtual keyboard: Simple Keyboard (see above, or choose your choice of non-Google keyboard here, tap on the App here to check its settings.)
      • Advanced
        • Spell checker: (Make sure Google isn’t involved here, I have this off anyway. Yeah, “sometimes it shows, haha” … mostly when I’m not quick enough proof-reading/ correcting :wink: .)
        • Auto-fill service: None (instead of Google)
    • Languages & input
      • Backup
        • Back up to Google Drive: Off
  • Google (I know it’s not at the end in reality, but some settings here are just links to settings in other places in the Settings tree, so I can leave them out here.)

    • Ads
      • Opt out of Ads Personalisation: On
    • Data & messaging
      • App preview messages: Off
    • Device connections
      • Devices
        • Show notifications: Off

Issues so far

  • Current DB Navigator (tested with 19.10.p03.02) crashed at start.
    A re-install after uninstalling it failed.
    Workaround: Earlier DB Navigator (tested with 19.04.p05.01 and 19.08.p03.00) worked.
    The issue was a split APK,
    logcat entry was “Package de.hafas.android.db blocked since it is missing required splits.”
    Solution: SAI (Split APKs Installer) from F-Droid can handle split APKs.
    Major catch: The App in question has to work first. Then you can export the split APK of it with SAI, and then you can install the resulting split APK with SAI again if needed
    (confirmed with 19.10.p03.02 by deactivating all syncing, adding my Google account, installing current DB Navigator from the Play Store, exporting the split APK with SAI, uninstalling the App, removing my Google account - losing all contacts because Google simply assigned them to this account, be safe with a backup! - , enable syncing again, installing the split APK with SAI).
    Side effect: Dealing with this confirmed the Play Store still works if I want it to, and DB Navigator didn’t break because of all the uninstalling of Android components.
  • Dialing *#*#4636#*#* doesn’t bring up the “Testing” menu.
    Seems to have resolved itself.
  • After the update to OS Build number 8901.2.A.0101.20191115 (and after every reboot since) Android complained about Carrier Services not being able to work correctly, if I wouldn’t give Google Play Services permissions to Body sensors, Calendar, Camera, Contacts, Microphone (it’s all in one place, see above) … I didn’t give the permissions, let’s just see if something breaks. Until now the phone was working fine.
30 Likes

Arity has not been updated since 12 Feb 2019

Messages I use Signal. It handles SMS as well.

Gmail: I use P=P, a K9 fork with PGP (and material design).

YouTube I use NewPipe instead.

1 Like