Tag Archives: Developer Preview

The first developer preview of Android 14

Posted by Dave Burke, VP of Engineering

Making Android work well for each and every one of the billions of Android users is a collaborative process between us, Android hardware manufacturers, and you, our developer community.

Illustration of badge style Android 14 logo

Today we're releasing the first Developer Preview of Android 14, and your feedback in these previews is a critical part of making Android better for everyone. Android 14 continues our work to improve your productivity as developers, along with enhancements to performance, privacy, security, and user customization. This preview is just the beginning, and we’ll have lots more to share as we move through the release cycle.

Android continues to deliver enhancements and new features year-round, and your Android 14 developer preview and Quarterly Platform Release (QPR) beta program feedback plays a key role in helping Android continuously improve. The Android 14 developer site has lots more information about the preview, including downloads for Pixel and the release timeline. We’re looking forward to hearing what you think, and thank you in advance for your continued help in making Android a platform that works for everyone.

Working across devices and form factors

Android 14 builds on the work done in Android 12L and 13 to support tablets and foldable form factors. To help you build apps that adapt to different screen sizes, we've created window size classes, sliding pane layout, Activity embedding, and box with constraints and more, all supported in Jetpack Compose. With every release, our goal is to make it easier for you to optimize your app across all Android surfaces.

To help streamline getting your apps ready we have updated our app quality guidance for large screens, and provided additional learning opportunities around building for large screens and foldables. The large screen gallery contains proven design patterns along with design inspiration around the markets that your app supports such as social and communications, media, productivity, shopping, and reading apps.

Multi-device experiences are a big part of the future of Android. You can get started today with the Cross device SDK preview, allowing you to build rich experiences that intuitively work across different devices and form factors, and there's more to come.

Streamlining background work

Android 14 continues our effort to optimize the way apps work together, improve system health and battery life, and polish the end-user experience.

Updates and additions to JobScheduler and Foreground Services

It's more complicated than necessary to perform some background work, such as downloading large files when WiFi is available. We're creating a standard path for this work to simplify your app development and potentially improve the user experience. We're also being more opinionated about how foreground services should be used, reserving them for only the highest priority user-facing tasks so that Android can improve resource consumption and battery life.

In Android 14, we are making changes to existing Android APIs (Foreground Services and JobScheduler) including adding new functionality for user-initiated data transfers, along with an updated requirement to declare foreground service types. The user-initiated data transfer job will make managing user initiated downloads and uploads easier, particularly when they require constraints such as downloading on Wi-Fi only. The requirement to declare foreground service types allows you to clearly define the intent of the background work of your app while making it clear which use-cases are appropriate for foreground services. In addition, Google Play will be rolling out new policies to ensure the appropriate use of these APIs, with more details coming soon.

Optimized broadcasts

We’ve made several optimizations to the internal broadcast system to improve battery life and responsiveness. While most of the optimizations are internal to Android and should not impact your apps, we have adjusted how apps receive context-registered broadcasts once the app goes into a cached state. Broadcasts to context-registered receivers may be queued and only delivered to the app once it comes out of the cached state. Furthermore, some repeating context-registered broadcasts, such as BATTERY_CHANGED, may be merged into one final broadcast before it is delivered once the app comes out of the cached state.

Exact alarms

The invocation of exact alarms can significantly affect the device's resources, such as battery life. So in Android 14, newly installed apps targeting Android 13+ (SDK 33+) that are not clocks or calendars must request the user to grant them the SCHEDULE_EXACT_ALARM special permission before setting exact alarms. Apps can direct users to the settings page via an intent to toggle this permission, but we encourage you to evaluate your use cases and choose more flexibly scheduled alternatives when possible.

Clock and calendar apps targeting Android 13+ (SDK 33+) that rely on exact alarms as part of their core app workflow will be able to declare the USE_EXACT_ALARM normal permission instead (granted on install). Apps will not be able to publish a version of their app to the Play store with this permission in the manifest unless they qualify based on the policy language.

Customization

We're continuing to make sure that Android users can tune their experience around their individual needs, including enhanced accessibility and internationalization features.

Bigger fonts with non-linear scaling

Starting in Android 14, users will be able to scale up their font to 200%. Previously, the maximum font size scale on Pixel devices was 130%.

To mitigate issues where text gets too large, starting in Android 14, a non-linear font scaling curve is automatically applied. This ensures that text that is already large enough doesn’t increase at the same rate as smaller text.
Examples of text scaling showing the differences between the sizing of standard font at 100% (no scaling)on the left, standard scaling (200%) in the middle, and non-linear scaling (200%)on the rightIn Android 14, you should test your app UI with the maximum font size using the Font size option within the Accessibility > Display size and text settings. Ensure that the adjusted large text size setting is reflected in the UI, and that it doesn’t cause text to be cut off. Our documentation has more on best practices.

Per-app language preferences

You can dynamically update your app's localeConfig with LocaleManager.setOverrideLocaleConfig to customize the set of languages displayed in the per-app language list in Android Settings. This allows you to customize the language list per region, run A/B experiments, and provide updated locales if your app utilizes server-side localization pushes.

IMEs can now use LocaleManager.getApplicationLocales to know the UI language of the current app to update the keyboard language.

Grammatical Inflection API

The Grammatical Infection API allows you to more easily add support for users who speak languages which have grammatical gender. For example,

Masculine: “Vous êtes abonné à...”

Feminine: “Vous êtes abonnée à…”

Neutral: “Abonnement à…activé”

Grammatical gender is inherent to the language and cannot be easily worked around in some non-English languages. This new API lowers the effort to support viewer gender (who’s viewing the UI; not who’s being talked about) as compared to using the SelectFormat in ICU which must be applied on a per string basis.

To show personalized translations, you just need to add translations inflected for each grammatical gender for impacted languages and integrate the API.

Privacy and Security

Runtime receivers

Apps targeting Android 14 must indicate if dynamic Context.registerReceiver() usage should be treated as "exported" or "unexported", a continuation of the manifest-level work from previous releases. Learn more here.

Safer implicit intents

To prevent malicious apps from intercepting intents, apps targeting Android 14 are restricted from sending intents internally that don't specify a package. Learn more here.

Safer dynamic code loading

Dynamic code loading (DCL) introduces outlets for malware and exploits, since dynamically downloaded executables can be unexpectedly manipulated, causing code injection. Apps targeting Android 14 require dynamically loaded files to be marked as read-only. Learn more here.

Block installation of apps

Malware often targets older API levels to bypass security and privacy protections that have been introduced in newer Android versions. To protect against this, starting with Android 14, apps with a targetSdkVersion lower than 23 cannot be installed. This specific version was chosen because some malware apps use a targetSdkVersion of 22 to avoid being subjected to the runtime permission model introduced in 2015 by Android 6.0 (API level 23).

On devices that upgrade to Android 14, any apps with a targetSdkVersion lower than 23 will remain installed.

You can test apps targeting an older API level using the following ADB command:

adb install --bypass-low-target-sdk-block FILENAME.apk

Credential Manager and Passkeys support

We recently announced the alpha release of Credential Manager, a new Jetpack API that allows you to simplify your users' authentication journey, while also increasing security with support of passkeys. Passkeys are a significantly safer replacement for passwords and other phishable authentication factors and more convenient for users (they require just a biometric swipe to securely sign in on any device). Read more here.

App compatibility

We’re working to make updates faster and smoother with each platform release by prioritizing app compatibility. In Android 14 we’ve made most app-facing changes opt-in to give you more time to make any necessary app changes, and we’ve updated our tools and processes to help you get ready sooner.

OpenJDK 17 Support - This preview includes access to 300 OpenJDK 17 classes. We are working hard to fully enable Java 17 language features in upcoming developer previews. These include record classes, multi-line strings and pattern matching instanceof. Thanks to Google Play system updates (Project Mainline), over 600M devices are enabled to receive the latest Android Runtime (ART) updates that include these changes. This is part of our commitment to give apps a more consistent, secure environment across devices, and to deliver new features and capabilities to users independent of platform releases.

Easier testing and debugging of changes - To make it easier for you to test the opt-in changes that can affect your app, we’ll make many of them toggleable again this year. With the toggles, you can force-enable or disable the changes individually from Developer options or adb. Check out the details here.
App compatibility toggles in Developer Options
Platform stability milestone - Like last year, we’re letting you know our Platform Stability milestone well in advance, to give you more time to plan for app compatibility work. At this milestone we’ll deliver final SDK/NDK APIs and also final internal APIs and app-facing system behaviors. We’re expecting to reach Platform Stability in June 2023, and from that time you’ll have several weeks before the official release to do your final testing. The release timeline details are here.

Get started with Android 14

The Developer Preview has everything you need to try the Android 14 features, test your apps, and give us feedback. For testing your app with tablets and foldables, the easiest way to get started is using the Android Emulator in a tablet or foldable configuration in the latest preview of the Android Studio SDK Manager. For phones, you can get started today by flashing a system image onto a Pixel 7 Pro, Pixel 7, Pixel 6a, Pixel 6 Pro, Pixel 6, Pixel 5a 5G, Pixel 5, or Pixel 4a (5G) device. If you don’t have a Pixel device, you can use the 64-bit system images with the Android Emulator in Android Studio.

For the best development experience with Android 14, we recommend that you use the latest preview of Android Studio Giraffe (or more recent Giraffe+ versions). Once you’re set up, here are some of the things you should do:

  • Try the new features and APIs - your feedback is critical during the early part of the developer preview. Report issues in our tracker on the feedback page.
  • Test your current app for compatibility - learn whether your app is affected by default behavior changes in Android 14; install your app onto a device or emulator running Android 14 and extensively test it.
  • Test your app with opt-in changes - Android 14 has opt-in behavior changes that only affect your app when it’s targeting the new platform. It’s important to understand and assess these changes early. To make it easier to test, you can toggle the changes on and off individually.

We’ll update the preview system images and SDK regularly throughout the Android 14 release cycle. This initial preview release is for developers only and not intended for daily or consumer use, so we're making it available by manual download only. Once you’ve manually installed a preview build, you’ll automatically get future updates over-the-air for all later previews and Betas. Read more here.

If you intend to move from the Android 13 QPR Beta program to the Android 14 Developer Preview program and don't want to have to wipe your device, we recommend that you move to Developer Preview 1 now. Otherwise you may run into time periods where the Android 13 Beta will have a more recent build date which will prevent you from going directly to the Android 14 Developer Preview without doing a data wipe.

As we reach our Beta releases, we'll be inviting consumers to try Android 14 as well, and we'll open up enrollment for the Android Beta program at that time. For now, please note that the Android Beta program is not yet available for Android 14.

For complete information, visit the Android 14 developer site.

Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.

Privacy Sandbox: Developer Preview 5 is here!

Posted by Fred Chung, Android Developer Relations

Today, we’re releasing the Privacy Sandbox on Android Developer Preview 5 ‒ it’s a major milestone that will become the foundation for upcoming Privacy Sandbox Beta releases.

We appreciate that many of you have tested the Developer Preview and have reported issues and shared your feedback. This feedback has helped us evolve the Privacy Sandbox design. For example, we have modified the SDK Runtime design to allow reflection API usage, and have published additional design proposals on FLEDGE services, mediation, and app-to-web measurement.

Let’s have a look at the specifics in this release.


What’s in Developer Preview 5?

Developer Preview 5 includes additional functionality, data validation enhancements, and API signature changes across the privacy preserving APIs and the SDK Runtime. See the release notes for details.


Attribution Reporting API



FLEDGE on Android API

  • To provide up-to-date data for auctions, you can set up a daily fetch URL to update custom audience AdData lists and other metadata.
  • This release incorporates various API signature changes and additional parameter validation to ensure robustness. Refer to the release notes for details. Be sure to update the sample code and your test projects using previous Developer Preview releases.


SDK Runtime

  • Apps get additional control on runtime enabled SDK lifecycle events, such as when the SDK is unexpectedly terminated by the platform. Implementing the SdkSandboxLifecycleCallback allows the app to take appropriate actions to recover.
  • After successfully loading an SDK, apps now have access to an IBinder interface to facilitate 2-way communications with the runtime-enabled SDK.


Topics API

  • Updated taxonomy for classification of mobile apps.


AdServices permissions

  • App developers must now declare AdServices permissions to access the privacy preserving APIs. Learn more.

In the coming months, we’ll continue to use the Developer Previews to innovate and implement new features. We’ll publish more details about the Beta and these future releases in the coming months.


Get started with Developer Preview 5

With today’s Developer Preview release, we hope to continue working with the industry and developers to get prepared for Privacy Sandbox on Android. The release provides the resources you need to begin early testing of features and share feedback. To get started developing, see instructions to set up the SDK and system images on the emulator or supported Pixel devices.

For more information on the Privacy Sandbox on Android Developer Preview, visit the developer site and sign up for our newsletter to receive regular updates.

Announcing Cross device SDK Developer Preview for building rich multi-device experiences on Android

Posted by Alex Rocha - Developer Relations Engineer Manager, Ryan Ausanka-Crues - Eng Manager, Multi-device development, Stella Loh - Product Manager, Multi-device development

Today we’re launching our Developer Preview of the new Cross device SDK for Android. First announced during the Google I/O ‘22 Multi-device development session, our Cross device SDK allows developers to build rich multi-device experiences with a simple and intuitive set of APIs. This SDK abstracts away the intricacies involved with working with device discovery, authentication, and connection protocols, allowing you to focus on what matters most—building delightful user experiences and connecting these experiences across a variety of form factors and platforms.

What’s in Developer Preview

This initial release contains a set of rich APIs centered around the core functionality of Device discovery, Secure connections, and Multi-device Sessions.

  1. Device discovery: Easily find nearby devices, authorize peer-to-peer communication, and start the target application on receiving devices.
  2. Secure connections: Enable encrypted, low-latency bi-directional data sharing between authorized devices.
  3. Multi-device Sessions: Enable transferring or extending an application’s user experience across multiple devices.

In turn, this will allow you to build compelling cross-device experiences by enabling and simplifying the following use cases:

  • Discovering and authorizing communication with nearby devices.
  • Sharing an app’s current state with the same app on another device.
  • Starting the app on a secondary device without having to keep the app running in background.
  • Establishing secure connections for devices to communicate with each other.
  • Enabling task handoff where the user starts a task on one device, and can easily continue on another device.

Starting today with a Developer Preview for Android phones and tablets, the Cross device SDK will be available later for other Android surfaces and non-Android OSs.

Under The Hood

The Cross device SDK provides a software abstraction layer that handles all aspects of cross-device connectivity, leveraging wireless technologies such as Bluetooth, Wi-Fi, and Ultra-wide band; our SDK does all the heavy-lifting under the hood, offering you a modular,connectivity-agnostic API that supports bi-directional communication between devices and is backward compatible to Android 8. In addition, apps will not have to declare or request Runtime Permissions for any of the underlying connectivity protocols used (such as BLUETOOTH_CONNECT, BLUETOOTH_SCAN, ACCESS_FINE_LOCATION, etc.), and the user can allow apps to connect to only the device(s) they selected.

Getting started with Developer Preview

Head over to our developer guide to get started and try out the Developer Preview of the Cross device SDK for Android. Make sure to check out our Rock Paper Scissor sample app (Kotlin and Java) on GitHub for a demonstration on how to work with the various APIs and our Google I/O ‘22 Multi-device development session for a general overview of the SDK.

Feedback

We’d love to hear from you during this initial Developer Preview launch to help us shape the SDK and influence future roadmapping, so please share your feedback and let us know your experience with the SDK!

Android 13 Beta 3 and Platform Stability

Posted by Dave Burke, VP of Engineering

Android13 Logo

Today we’re releasing the third Beta of Android 13, taking us into the final phase of our cycle where we’re focusing on polish and performance. With Android 13, we’ve built on our core themes of privacy and security, developer productivity, and tablet and large screen support.

There’s a lot to explore in Android 13, from privacy features like the new notification permission and photo picker, to productivity features like themed app icons and per-app language support, as well as modern standards like HDR video, Bluetooth LE Audio, and MIDI 2.0 over USB. We’ve also extended the newer updates we made in 12L, giving you better tools to take advantage of the 270+ million tablet and large screen devices in active use.

Beta 3 takes Android 13 to Platform Stability, which means that the developer APIs and all app-facing behaviors are now final. We’re thankful for all the feedback you’ve shared to help us get to this point! For developers, the focus is now on compatibility testing and quality as you prepare your apps for the official release later in the year!

You can get Beta 3 on your Pixel device by enrolling here for over-the-air updates. If you previously enrolled, you’ll automatically get today’s update. You can also try Android 13 Beta on select devices from several of our partners - learn more at android.com/beta. Read on for a quick look at how to get your app ready, and visit the Android 13 developer site for details.


Platform Stability

With Beta 3, Android 13 reaches Platform Stability, a milestone that means all app-facing behaviors and APIs, including the official API Level 33 SDK and NDK APIs, are now final. So from Beta 3, you can confidently develop and release your compatibility updates knowing that the platform won’t change.

Platform stability timeline with stable at the June mark

We’re asking all app and game developers to start your final compatibility testing now and prepare to publish your compatibility updates as soon as possible ahead of the final release.

For all SDK, library, tools, and game engine developers, it’s even more important to start testing now and release your compatible updates as soon as possible -- your downstream app and game developers may be blocked until they receive your updates. So when you’ve released a compatible update, be vocal and let your developers know!


App compatibility

App compatibility means that your app runs as intended on a new version of the platform. With each release, we make integral changes to the platform that improve privacy and security and the overall user experience across the OS. These can affect your apps, so it’s important to test your app now, make any updates needed, and publish a compatible update to your users ahead of the final release. It’s a basic but critical level of quality that your users will appreciate as they explore what’s new in Android 13.

To test your app for compatibility, just install your production app from Google Play or other source onto a device running Android 13 Beta 3. Work through all of the app’s flows and watch for functional or UI issues. Review the behavior changes to focus your testing. Here are some changes to watch for:

  • Runtime permission for notifications - Android 13 introduces a new runtime permission for sending notifications from an app. Make sure you understand how the new permission works, and plan on targeting Android 13 (API 33) as soon as possible. More here.
  • Clipboard preview - Make sure your app hides sensitive data in Android 13’s new clipboard preview, such as passwords or credit card information. More here.
  • JobScheduler prefetch - JobScheduler now tries to anticipate the next time your app will be launched and will run any associated prefetch jobs ahead of that time. If you use prefetch jobs, test that they are working as expected. More here.

Also remember to test the libraries and SDKs in your app for compatibility. If you find any issues, try updating to the latest version of the library or SDK or reaching out to the developer for help.

Once you’ve published the compatible version of your current app, you can start the process to update your app's targetSdkVersion. Review the behavior changes for apps targeting Android 13 and use the compatibility framework to help you detect issues quickly. Here are some of the changes to test for (these apply only to apps with targetSdkVersion set to API 33 or higher):

  • Nearby device permission for Wi-Fi - Apps that manage a device's connections to nearby access points should use a new NEARBY_WIFI_DEVICES runtime permission for Wi-Fi operations like scanning, without needing access to device location. Some Wi-Fi APIs require your app to have this new permission. More here.
  • Granular media permissions - If your app targets Android 13 and reads media files from common data storage, you must request one or more of the new granular permissions instead of the READ_EXTERNAL_STORAGE permission. More here.
  • Permission changes for body sensors - Android 13 introduces "while in use" access for body sensors. If your app needs to access body sensor information from the background, it must declare a new BODY_SENSORS_BACKGROUND permission. More here.
  • Intent filters block non-matching intents - If your app sends an intent to an exported component of another app targeting Android 13 (API 33) or higher, it now needs to match an intent filter in the receiving app. More here.
  • Media controls derived from PlaybackState - Android 13 derives more media controls from PlaybackState actions, to show a richer set of controls that are consistent across device types. Make sure your app handles these changes. More here

Tablets and large-screens support

Android 13 builds on the tablet optimizations introduced in 12L, so as part of your testing, make sure your apps look their best on tablets and other large-screen devices. You can test with the large screens features by setting up an Android emulator in Android Studio, or you can use a large screen device from our Android 13 Beta partners. Here are some areas to watch for:

  • Taskbar interaction - Check how your app responds when viewed with the new taskbar on large screens. Make sure your app's UI isn't cut off or blocked by the taskbar. More here.
  • Multi-window mode - Multi-window mode is now enabled by default for all apps, regardless of app configuration, so make sure the app handles split-screen appropriately. You can test by dragging and dropping your app into split-screen mode and adjusting the window size. More here.
  • Improved compatibility experience - if your app isn’t optimized for tablets yet, such as using a fixed orientation or not being resizable, check how your app responds to compatibility mode adjustments such as letterboxing. More here.
  • Media projection - If your app uses media projection, check how your app responds while playing back, streaming, or casting media on large screens. Be sure to account for device posture changes on foldable devices as well. More here.
  • Camera preview - For camera apps, check how your camera preview UI responds on large screens when your app is constrained to a portion of the screen in multi-window or split-screen mode. Also check how your app responds when a foldable device's posture changes. More here.

You can read more about the tablet features in Android 13 and what to test here.


Get started with Android 13!

Today’s Beta release has everything you need to test your app and try the Android 13 features. Just enroll your Pixel device to get the update over-the-air. To get started, set up the Android 13 SDK.

You can also test your app with Android 13 Beta on devices from several of our partners. Visit android.com/beta to see the full list of partners, with links to their sites for details on their supported devices and Beta builds, starting with Beta 1. Each partner will handle their own enrollments and support, and provide the Beta updates to you directly. For even broader testing, you can try Android 13 Beta 3 on Android GSI images, and if you don’t have a device, you can test on the Android Emulator.

For complete details on Android 13, visit the Android 13 developer site.

The Beta for Android 13 is out now: Android 13 Beta 1

Posted by Dave Burke, VP of Engineering

Android13 Logo

It’s already April and we’ve been making steady progress refining the features and stability of Android 13, building around our core themes of privacy and security, developer productivity, as well as tablet and large screen support. Today we’re moving into the next phase of our cycle and releasing the first Beta of Android 13.

For developers, there’s a lot to explore in Android 13, from privacy features like the new notification permission and photo picker, to APIs that help you build great experiences, like themed app icons, quick settings tile placement, and per-app language support, as well as capabilities like Bluetooth LE audio and MIDI 2.0 over USB. In Beta 1, we’ve added new permissions for more granular access to media files, improved audio routing APIs, and more. We’ll have more to share at Google I/O, coming up on May 11-12, so please save the date!

We’re inviting you to give Beta 1 a try as we welcome more early adopters to give us feedback on this release. You can try Android 13 Beta 1 today on supported Pixel devices by enrolling here to get the update over-the-air. If you’re already running a developer preview of Android 13, your device will automatically get this and future updates over the air. As always, downloads for Pixel and the Android Emulator are also available. Visit the Android 13 developer site for details on how to get started developing and testing your app.


What’s new in Beta 1?

We’re continuing to focus on privacy and security, while giving you new APIs to help you build great experiences for your users. Beta 1 includes the latest updates to features we announced earlier, like the new notification permission, photo picker, themed app icons, improved localization and language support, and more. Beta 1 also introduces a small number of new features, so give these a try and let us know what you think!

More granular permissions for media file access - Previously, when an app wanted to read shared media files in local storage, it needed to request the READ_EXTERNAL_STORAGE permission, which gave access to all types of media files. To bring more transparency and control to users, we’re introducing a new set of permissions with more granular scope for accessing shared media files.

With the new permissions, apps now request access to a specific type of file in shared storage:

Allow My App to access music and other audio files on this device

When the permissions are granted by the user, apps will have read access to the respective media file types. To simplify the experience for users, If an app requests READ_MEDIA_IMAGE and READ_MEDIA_VIDEO at the same time, the system displays a single dialog for granting both permissions. If your app accesses shared media files, you’ll need to migrate to the new permissions when your app targets Android 13. More here.

Better error reporting in Keystore and KeyMint - For apps that generate keys, Keystore and KeyMint now provide more detailed and accurate error indicators. We’ve added an exception class hierarchy under java.security.ProviderException, with Android-specific exceptions that include Keystore/KeyMint error codes, and whether the error is retryable. You can also modify the methods for key generation, signing, and encryption to throw the new exceptions. The improved error reporting should now give you what you need to retry key generation.

Anticipatory audio routing - To help media apps identify how their audio is going to be routed, we’ve added new audio route APIs in the AudioManager class. The new getAudioDevicesForAttributes() API allows you to retrieve a list of devices that may be used to play the specified audio, and we added the getDirectProfilesForAttributes() API to help you understand whether your audio stream can be played directly. Use these new APIs to determine the best AudioFormat to use for your audio track.

App compatibility

If you haven’t tested your app for compatibility with Android 13 yet, now is the time to do it! With Android 13 now in Beta, we’re opening up access to early-adopter users as well as developers. This means that in the weeks ahead, you can expect more users to be trying your app on Android 13 and raising any issues that they find.

To test for compatibility, install your published app from Google Play or other source on a device or emulator running Android 13 Beta and work through all of the app’s flows. Review the behavior changes to focus your testing. After you’ve resolved any issues, publish an update as soon as possible.

Timeline

With Beta we’re getting closer to Platform Stability in June 2022. Starting then, app-facing system behaviors, SDK/NDK APIs, and non-SDK lists will be finalized. At that time, you should finish up your final compatibility testing and release a fully compatible version of your app, SDK, or library. More on the timeline for developers is here.


Get started with Android 13!

Today’s Beta release has everything you need to try the Android 13 features, test your apps, and give us feedback. Just enroll any supported Pixel device here to get this and future Android 13 Beta and feature drop Beta updates over-the-air. If you’ve already installed a developer preview build, you’ll automatically get these updates. To get started developing, set up the SDK.

For even broader testing on supported devices, try Android 13 Beta on Android GSI images, and if you don’t have a device you can test on the Android Emulator -- just download the latest emulator system images via the SDK Manager in Android Studio.

For complete details on how to get the Beta, visit the Android 13 developer site.

Android 13 Developer Preview 2

Posted by Dave Burke, VP of Engineering

Android13 Logo

Last month, we released the first developer preview of Android 13, built around our core themes of privacy and security, developer productivity, as well as tablets and large screen support. Today we’re sharing Android 13 Developer Preview 2 with more new features and changes for you to try in your apps. Your input helps us make Android a better platform for developers and users, so let us know what you think!

Today’s release also comes on the heels of the 12L feature drop moving to the Android Open Source Project (AOSP) last week, helping you better take advantage of the over 250+ million large screen Android devices. And to dive into Android 13, tablets, as well as our developer productivity investments in Jetpack Compose, check out the latest episode of #TheAndroidShow.


12L feature drop, now in AOSP

Before jumping into Developer Preview 2, let’s take a look at the other news from last week: we’ve officially released the 12L feature drop to AOSP and it’s rolling out to all supported Pixel devices over the next few weeks. 12L makes Android 12 even better on tablets, and includes updates like a new taskbar that lets users instantly drag and drop apps into split-screen mode, new large-screen layouts in the notification shade and lockscreen, and improved compatibility modes for apps. You can read more here.

Starting later this year, 12L will be available in planned updates on tablets and foldables from Samsung, Lenovo, and Microsoft, so now is the time to make sure your apps are ready. We highly recommend testing your apps in split-screen mode with windows of various sizes, trying it in different orientations, and checking the new compatibility mode changes if they apply. You can read more about 12L for developers here.

And the best part: the large screen features in 12L are foundational in Android 13, so you can develop and test on Android 13 knowing that you’re also covering your bases for tablets running Android 12L. We see large screens as a key surface for the future of Android, and we’re continuing to invest to give you the tools you need to build great experiences for tablets, Chromebooks, and foldables. You can learn more about how to get started optimizing for large screens, and make sure to check out our large screens developer resources.

Let’s dive into what’s new in today’s Developer Preview 2 of Android 13.


Privacy and user trust

People want an OS and apps that they can trust with their most personal and sensitive information and the resources on their devices. Privacy and user trust are core to Android’s product principles, and in Android 13 we’re continuing to focus on building a responsible and high quality platform for all by providing a safer environment on the device and more controls to the user. Here’s what’s new in Developer Preview 2.

Notification permission - To help users focus on the notifications that are most important to them, Android 13 introduces a new runtime permission for sending notifications from an app: POST_NOTIFICATIONS. Apps targeting Android 13 will now need to request the notification permission from the user before posting notifications. For apps targeting Android 12 or lower, the system will handle the upgrade flow on your behalf. The flow will continue to be fine tuned. To provide more context and control for your users, we encourage you to target Android 13 as early as possible and request the notification permission in your app. More here.

Notification permission dialog in Android 13.

Notification permission dialog in Android 13.

Developer downgradable permissions - Some apps may no longer require certain permissions which were previously granted by the user to enable a specific feature, or retain a sensitive permission from an older Android version. In Android 13, we’re providing a new API to let your app protect user privacy by downgrading previously granted runtime permissions.

Safer exporting of context-registered receivers - In Android 12 we required developers to declare the exportability of manifest-declared Intent receivers. In Android 13 we’re asking you to do the same for context-registered receivers as well, by adding either the RECEIVER_EXPORTED or RECEIVER_NOT_EXPORTED flag when registering receivers for non-system sources. This will help ensure that receivers aren’t available for other applications to send broadcasts to unless desired. While not required in Android 13, we recommend declaring exportability as a step toward securing your app.


Developer productivity

In Android 13 we’re working to give you more tools to help you deliver a polished experience and better performance for users. Here are some of the updates in today’s release.

Improved Japanese text wrapping - TextViews can now wrap text by Bunsetsu (the smallest unit of words that sounds natural) or phrases -- instead of by character -- for more polished and readable Japanese applications. You can take advantage of this wrapping by using android:lineBreakWordStyle="phrase" with TextViews.

Japanese text wrapping with phrase style
enabled (bottom) and without (top)

Japanese text wrapping with phrase style enabled (bottom) and without (top).

Improved line heights for non-latin scripts - Android 13 improves the display of non-Latin scripts (such as Tamil, Burmese, Telugu, and Tibetan) by using a line height that’s adapted for each language. The new line heights prevent clipping and improve the positioning of characters. Your app can take advantage of these improvements just by targeting Android 13. Make sure to test your apps when using the new line spacing, since changes may affect your UI in non-Latin languages.

Target SDK for Android 12 and 13

Improved line height for non-Latin scripts in apps targeting Android 13 (bottom).

Text Conversion APIs - People who speak languages like Japanese and Chinese use phonetic lettering input methods, which often slow down searching and features like auto-completion. In Android 13, apps can call the new text conversion API so users can find what they're looking for faster and easier. Previously, for example, searching required a Japanese user to (1) input Hiragana as the phonetic pronunciation of their search term (i.e. a place or an app name), (2) use the keyboard to convert the Hiragana characters to Kanji, (3) re-search using the Kanji characters to (4) get their search results. With the new text conversion API, Japanese users can type in Hiragana and immediately see Kanji search results live, skipping steps 2 and 3.

Color vector fonts - Android 13 adds rendering support for COLR version 1 (spec, intro video) fonts and updates the system emoji to the COLRv1 format. COLRv1 is a new, highly compact, font format that renders quickly and crisply at any size. For most apps this will just work, the system handles everything. You can opt in to COLRv1 for your app starting in Developer Preview 2. If your app implements its own text rendering and uses the system's fonts, we recommend opting in and testing emoji rendering. Learn more about COLRv1 in the Chrome announcement.

COLRv1 vector emoji (left) and bitmap emoji

COLRv1 vector emoji (left) and bitmap emoji.

Bluetooth LE Audio - Low Energy (LE) Audio is the next-generation wireless audio built to replace Bluetooth classic and enable new use cases and connection topologies. It will allow users to share and broadcast their audio to friends and family, or subscribe to public broadcasts for information, entertainment, or accessibility. It’s designed to ensure that users can receive high fidelity audio without sacrificing battery life and be able to seamlessly switch between different use cases that were not possible with Bluetooth Classic. Android 13 adds built-in support for LE Audio, so developers should get the new capabilities for free on compatible devices.

MIDI 2.0 - Android 13 adds support for the new MIDI 2.0 standard, including the ability to connect MIDI 2.0 hardware through USB. This updated standard offers features such as increased resolution for controllers, better support for non-Western intonation, and more expressive performance using per-note controllers.


App compatibility

With each platform release, we’re working to make updates faster and smoother by prioritizing app compatibility as we roll out new platform versions. In Android 13 we’ve made app-facing changes opt-in to give you more time, and we’ve updated our tools and processes to help you get ready sooner.

With Developer Preview 2, we’re well into the release and continuing to improve overall stability, so now is the time to try the new features and changes and give us your feedback. We’re especially looking for input on our APIs, as well as details on how the platform changes affect your apps. Please visit the feedback page to share your thoughts with us or report issues.

timeline 

It’s also a good time to start your compatibility testing and identify any work you’ll need to do. We recommend doing the work early, so you can release a compatible update by Android 13 Beta 1. There’s no need to change your app’s targetSdkVersion at this time, but we do recommend using the behavior change toggles in Developer Options to get a preliminary idea of how your app might be affected by opt-in changes in Android 13.

As we reach Platform Stability in June 2022, all of the app-facing system behaviors, SDK/NDK APIs, and non-SDK lists will be finalized. At that point, you can wind up your final compatibility testing and release a fully compatible version of your app, SDK, or library. More on the timeline for developers is here.

App compatibility toggles in Developer Options.

App compatibility toggles in Developer Options.


Get started with Android 13

The Developer Preview has everything you need to try the Android 13 features, test your apps, and give us feedback. You can get started today by flashing a device system image to a Pixel 6 Pro, Pixel 6, Pixel 5a 5G, Pixel 5, Pixel 4a (5G), Pixel 4a, Pixel 4 XL, or Pixel 4 device. If you don’t have a Pixel device, you can use the 64-bit system images with the Android Emulator in Android Studio Dolphin. For even broader testing, GSI images are available. If you’ve already installed a preview build to your Pixel device, you’ll automatically get this update and all later previews and Betas over the air. More details on how to get Android 13 are here.

For complete information, visit the Android 13 developer site.

The first developer preview of Android 13

Posted by Dave Burke, VP of Engineering

Android13 Logo

Every day, billions of people around the world pull out their Android device to help them get things done. That Android works well for each and every one of them is ensured in part through a collaborative process with you, our developer community, sharing feedback to help us make Android stronger.

Today, we’re sharing a first look at the next release of Android, with the Android 13 Developer Preview 1. With Android 13 we’re continuing some important themes: privacy and security, as well as developer productivity. We’ll also build on some of the newer updates we made in 12L to help you take advantage of the 250+ million large screen Android devices currently running.

This is just the start for Android 13, and we’ll have lots more to share as we move through the release. Read on for a taste of what’s new, and visit the Android 13 developer site for details on downloads for Pixel and the release timeline. As always, it’s crucial to get your feedback early, to help us include it in the final release. We’re looking forward to hearing what you think, and thanks in advance for your continued help in making Android a platform that works for everyone!


Privacy & security at the core

People want an OS and apps that they can trust with their most personal and sensitive information. Privacy is core to Android’s product principles, and Android 13 focuses on building a responsible and high quality platform for all by providing a safer environment on the device and more controls to the user. In today’s release, we’re introducing a photo picker that allows users to share photos and videos securely with apps, and a new Wi-Fi permission to further minimize the need for apps to have the location permission. We recommend trying out the new APIs and testing how the changes may affect your app.

Photo picker and APIs - To help protect photo and video privacy of users, Android 13 adds a system photo picker — a standard and optimized way for users to share both local and cloud-based photos securely. Android’s long standing document picker allows a user to share specific documents of any type with an app, without that app needing permission to view all media files on the device. The photo picker extends this capability with a dedicated experience for picking photos and videos. Apps can use the photo picker APIs to access the shared photos and videos without needing permission to view all media files on the device. We plan to bring the photo picker experience to more Android users through Google Play system updates, as part of a MediaProvider module update for devices (excepting Go devices) running Android 11 and higher. Give photo picker APIs a try and let us know your feedback!


Photo picker provides a consistent, secure way for users to give apps access to specific photos and videos.

Photo picker provides a consistent, secure way for users
to give apps access to specific photos and videos.


Nearby device permission for Wi-Fi - Android 13 introduces the NEARBY_WIFI_DEVICES runtime permission (part of the NEARBY_DEVICES permission group) for apps that manage a device's connections to nearby access points over Wi-Fi. The new permission will be required for apps that call many commonly-used Wi-Fi APIs, and enables apps to discover and connect to nearby devices over Wi-Fi without needing location permission. Previously, the location permission requirements were a challenge for apps that needed to connect to nearby Wi-Fi devices but didn’t actually need the device location. Apps targeting Android 13 will be now able to request the NEARBY_WIFI_DEVICES permission with the “neverForLocation” flag instead, which should help promote a privacy-friendly app design while reducing friction for developers. Learn more.


Developer productivity and tools

Android 13 also brings new features and tools for developer productivity. Helping you create beautiful apps that run on billions of devices is one of our core missions – whether it’s in Android 13 or through our tools for modern Android development, like a language you love in Kotlin or opinionated APIs with Jetpack. By helping you work more productively, we aim to lower your cost of development so you can focus on continuing to build amazing experiences. Here’s some of what’s new in today’s release.

Quick Settings Placement API - Quick Settings in the notification shade is a convenient way for users to change settings or take quick actions without leaving the context of an app. For apps that provide custom tiles, we’re making it easier for users to discover and add your tiles to Quick Settings. Using a new tile placement API, your app can now prompt the user to directly add your custom tile to the set of active Quick Settings tiles. A new system dialog lets the user add the tile in one step, without leaving your app, rather than having to go to Quick Settings to add the tile.


Tile service sample wants to add the following tile to Quick Settings Alert 

Themed app icons - In Android 13 we’re extending Material You dynamic color beyond Google apps to all app icons, letting users opt into icons that inherit the tint of their wallpaper and other theme preferences. All your app needs to supply is a monochromatic app icon (for example, your notification drawable) and a tweak to the adaptive icon XML. We’re encouraging all developers to provide compatible icons to help provide a consistent experience for users who have opted in. Themed app icons are initially supported on Pixel devices and we’re working with our device manufacturer partners to bring them to more devices. Learn more.


Three phone screens. The first screen has themed icons disabled. The second has themed icons enabled. And the third has themed icons & dark theme enabled 

Per-app language preferences - Some apps let users choose a language that differs from the system language, to meet the needs of multilingual users. Such apps can now call a new platform API to set or get the user’s preferred language, helping to reduce boilerplate code and improve compatibility when setting the app’s runtime language. For broader compatibility, we'll be adding a similar API in an upcoming Jetpack library. Learn more.

Faster hyphenation - Hyphenation makes wrapped text easier to read and helps make your UI more adaptive. In Android 13 we’ve optimized hyphenation performance by as much as 200% so you can now enable it in your TextViews with almost no impact on rendering performance. To enable faster hyphenation, use the new fullFast or normalFast frequencies in setHyphenationFrequency(). Give faster hyphenation a try and let us know what you think!

Programmable shaders - Android 13 adds support for programmable RuntimeShader objects, with behavior defined using the Android Graphics Shading Language (AGSL). AGSL shares much of its syntax with GLSL, but works within the Android rendering engine to customize painting within Android's canvas as well as filtering of View content. Android internally uses these shaders to implement ripple effects, blur, and stretch overscroll, and Android 13 enables you to create similar advanced effects for your app.


AGSL animated shader

AGSL animated shader, adapted
from this GLSL Shader

OpenJDK 11 updates - In Android 13 we’ve started the work of refreshing Android's Core Libraries to align with the OpenJDK 11 LTS release, with both library updates and Java 11 programming language support for app and platform developers. We also plan to bring these Core Library changes to more devices through Google Play system updates, as part of an ART module update for devices running Android 12 and higher. Learn more.


App compatibility

With each platform release we’re working to make updates faster and smoother by prioritizing app compatibility as we roll out new platform versions. In Android 13 we’ve made most app-facing changes opt-in to give you more time, and we’ve updated our tools and processes to help you get ready sooner.

More of Android updated through Google Play - In Android 13 we’re continuing to expand our investment in Google Play system updates (Project Mainline) to give apps a more consistent, secure environment across devices, and to deliver new features and capabilities to users. We can now push new features like photo picker and OpenJDK 11 directly to users on older versions of Android through updates to existing modules. We’ve also added new modules, such as the Bluetooth and Ultra wideband modules, to further expand the scope of Android’s updatable core functionality.

Optimizing for tablets, foldables, and Chromebooks - With all the momentum in large screen devices like tablets, foldables, and Chromebooks, now is the time to get your apps ready for these devices and design fully adaptive apps that fit any screen. You can get started using our guidance on optimizing for tablets, then learn how to build for large screens and develop for foldables.

Easier testing and debugging of changes - To make it easier for you to test the opt-in changes that can affect your app, we’ll make many of them toggleable again this year. WIth the toggles you can force-enable or disable the changes individually from Developer options or adb. Check out the details here.


App compatibility toggles in Developer Options.

App compatibility toggles in Developer Options.


Platform stability milestone - Like last year, we’re letting you know our Platform Stability milestone well in advance, to give you more time to plan for app compatibility work. At this milestone we’ll deliver not only final SDK/NDK APIs, but also final internal APIs and app-facing system behaviors. This year we’re expecting to reach Platform Stability in June 2022, and from that time you’ll have several weeks before the official release to do your final testing. The release timeline details are here.


Timeline. February and March Developer Previews. April-Final Release Beta Releases. June-Final Release Platform Stability 

Get started with Android 13

The Developer Preview has everything you need to try the Android 13 features, test your apps, and give us feedback. For testing your app with tablets and foldables, the easiest way to get started is using the Android Emulator in a tablet or foldable configuration - complete setup instructions are here. For phones, you can get started on a device today by flashing a system image to a Pixel 6 Pro, Pixel 6, Pixel 5a 5G, Pixel 5, Pixel 4a (5G), Pixel 4a, Pixel 4 XL, or Pixel 4 device. If you don’t have a Pixel device, you can use the 64-bit system images with the Android Emulator in Android Studio. For even broader testing, GSI images are available.

When you’re set up, here are some of the things you should do:

  • Try the new features and APIs - your feedback is critical during the early part of the developer preview. Report issues in our tracker or give us direct feedback by survey for selected features from the feedback and requests page.
  • Test your current app for compatibility - learn whether your app is affected by default behavior changes in Android 13. Just install your current published app onto a device or emulator running Android 13 and test.
  • Test your app with opt-in changes - Android 13 has opt-in behavior changes that only affect your app when it’s targeting the new platform. It’s extremely important to understand and assess these changes early. To make it easier to test, you can toggle the changes on and off individually.

We’ll update the preview system images and SDK regularly throughout the Android 13 release cycle. This initial preview release is for developers only and not intended for daily or consumer use, so we're making it available by manual download only. Once you’ve manually installed a preview build, you’ll automatically get future updates over-the-air for all later previews and Betas. More here.

As we reach our Beta releases, we'll be inviting consumers to try Android 13 as well, and we'll open up enrollments for the Android Beta program at that time. For now, please note that Android Beta is not yet available for Android 13.

For complete information, visit the Android 13 developer site.

Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.