Zygote
API 28 · P

Android 9 Pie

Gesture navigation

released
2018-08-06
runtime
ART
design
Material (Material Theme)
status
stable

The story

Android 9 was about intelligence and restraint: adaptive battery, gesture navigation, and a platform that policed itself.

The problem

Battery life was dominated by apps doing background work, and the platform had no way to stop them.

Pie added App Standby Buckets, adaptive battery, gesture navigation, and the first restrictions on non-SDK interfaces. Cleartext HTTP was blocked by default.

The one thing to remember

Android started enforcing its own rules on apps.

What shipped

  • Gesture navigation
  • Adaptive Battery and App Actions
  • Digital Wellbeing
  • Dark theme groundwork
  • Adaptive brightness with AI

Platform internals

What changed underneath the APIs. These are the changes this site's architecture modules explain in depth.

  • App Standby Buckets
  • Mainline groundwork
  • Non-SDK interface restrictions (greylists) begin
  • BiometricPrompt

What developers had to deal with

  • Non-SDK interface restrictions
  • Foreground service permission
  • Cleartext HTTP blocked by default when targeting 28
  • Private DNS
  • Cutout support

Behaviour changes

The full archive has every recorded change with its migration advice.

targetingnetwork

Cleartext traffic is blocked by default

Apps targeting Android 9 cannot make cleartext HTTP connections unless they opt in.

What to doUse HTTPS. If cleartext is unavoidable for a specific domain, add a network security config exception.

targetingruntime

Non-SDK interface restrictions

Apps targeting Android 9 are restricted from using hidden APIs through reflection.

What to doReplace hidden API usage with public equivalents; check the API reference.

targetingbackground

Foreground service permission

Foreground services require the FOREGROUND_SERVICE permission.

What to doDeclare FOREGROUND_SERVICE and, from Android 14, the per-type permissions.

targetingui

Display cutout support

Apps must handle display cutouts and their insets.

What to doUse WindowInsets and avoid assuming a rectangular display.

targetingmedia

Background sensor access is restricted

Apps cannot access the microphone or camera from the background.

What to doAccess sensors only while visible, or with an appropriate foreground service.

all appsstorage

External storage permission changes

READ_EXTERNAL_STORAGE no longer grants access to some paths.

What to doUse MediaStore or the Storage Access Framework.

all appsnetwork

Private DNS

DNS queries can be encrypted with DNS over TLS.

What to doNo app change; be aware that hard-coded DNS assumptions may fail.

Permissions introduced here

  • ACCEPT_HANDOVERdangerous
  • FOREGROUND_SERVICEnormal
  • NFC_TRANSACTION_EVENTnormal
  • USE_BIOMETRICnormal

Where this sits

Release 28 of 37 API levels, by date
Headline features
5
Architecture changes
4
Developer changes
5
Sources cited
4

Kernel

This release shipped on Linux kernel versions 4.4, 4.9. Kernel versions vary by device.