Category Archives: Android Developers Blog

An Open Handset Alliance Project

Jetpack DataStore – wrap up

Posted by Simona Stojanovic, Android Developer Relations Engineer

MADSkills Jetpack DataStore 

Now that our MAD Skills series on Jetpack DataStore is complete, let’s do a quick wrap up of all the things we’ve covered in each episode:


Episode 1 — Introduction to Jetpack DataStore

We started with the basics of Jetpack DataStore — how it works and the changes and improvements it brings compared to SharedPreferences. We also discussed how to decide between its two implementations, Preferences and Proto DataStore, as well as how to choose between DataStore and Room.

Check out the blog post and the video:


Episode 2 — All about Preferences DataStore

Go deeper into Preferences DataStore: how to create it, read, and write data and how to handle exceptions, all of which should, hopefully, provide you with enough information to decide if it’s the right choice for your app.

Here’s the blog post and the video:


Episode 3 — All about Proto DataStore

Learn about Proto DataStore: how to create it, read, and write data and how to handle exceptions, to better understand the scenarios that make Proto a great choice.

If you prefer reading, here’s the blog post, otherwise, here’s the video:


Episode 4 — DataStore-serialization, sync work, and dependency injection

Episode 4 introduces several different concepts related to DataStore to understand how it works under the hood, so that you have everything at your disposal to use it in a production environment. We focus on: Kotlin Data class serialization, synchronous work, and dependency injection with Hilt.

Take a look at our blogs and video:

DataStore and dependency injection

DataStore and Kotlin serialization

DataStore and synchronous work


Episode 5 — DataStore-handling data migration and testing

Finally, in the fifth episode of our Jetpack DataStore series, we cover two additional concepts around DataStore: DataStore-to-DataStore migrations and testing. Hopefully, this will provide you all the information you need to add DataStore to your app successfully.

Check out the blogs and the video:

DataStore and data migration

DataStore and testing

Play Time with Jetpack Compose

Learn about Google Play Store’s strategy for adopting Jetpack Compose, how they overcame specific performance challenges, and improved developer productivity and happiness.

Posted by Andrew Flynn & Jon Boekenoogen, Tech leads on Google Play

In 2020, Google Play Store engineering leadership made the big decision to revamp its entire storefront tech stack. The existing code was 10+ years old and had incurred tremendous tech debt over countless Android platform releases and feature updates. We needed new frameworks that would scale to the hundreds of engineers working on the product while not negatively impacting developer productivity, user experience, or the performance of the store itself.

We laid out a multi-year roadmap to update everything in the store from the network layer all the way to the pixel rendering. As part of this we also wanted to adopt a modern, declarative UI framework that would satisfy our product goals around interactivity and user delight. After analyzing the landscape of options, we made the bold (at the time) decision to commit to Jetpack Compose, which was still in pre-Alpha.

Since that time, the Google Play Store and Jetpack Compose teams at Google have worked extremely closely together to release and polish a version of Jetpack Compose that meets our specific needs. In this article we'll cover our approach to migration as well as the challenges and benefits we found along the way, to share some insight into what adopting Compose can be like for an app with many contributors.

Play Store rewrote their UI with 50% less code with Compose

Considerations

When we were considering Jetpack Compose for our new UI rendering layer, our top two priorities were:

  1. Developer Productivity: Play Store team has hundreds of engineers contributing to this code, so it should be easy (and fun) to develop against.
  2. Performance: Play Store renders lots of media-heavy content with many business metrics that are very sensitive to latency and jank, so we needed to make sure it performed well across all devices, especially low-memory hardware and Android (Go Edition) devices.

Developer Productivity

We have been writing UI code using Jetpack Compose for over a year now and enjoy how Jetpack Compose makes UI development more simple.

We love that writing UI requires much less code, sometimes up to 50%. This is made possible by Compose being a declarative UI framework and harnessing Kotlin’s conciseness. Custom drawing and layouts are now simple function calls instead of View subclasses with N method overrides.

Using the Ratings Table as an example:

ratings table

With Views, this table consists of:

  • 3 View classes total, with 2 requiring custom drawing for the rounded rects, and stars
  • ~350 lines of Java, 55 lines of XML

With Compose, this table consists of:

  • All @Composable functions contained in the same file and language!
  • ~210 lines of Kotlin

buffering GIF

Animations are a hailed feature of Compose for their simplicity and expressiveness. Our team is building motion features that delight our Play Store users more than ever with Compose. With Compose’s declarative nature and animations APIs, writing sequential or parallel animations has never been easier. Our team no longer fears all the corner cases of animations around cancellation and call back chaining. Lottie, a popular animation library, already provides Compose APIs that are simple to work with.

Now you might be thinking: this all sounds great, but what about library dependencies that provide Views? It's true, not all library owners have implemented Compose-based APIs, especially when we first migrated. However, Compose provides easy View interoperability with its ComposeView and AndroidView APIs. We successfully integrated with popular libraries like ExoPlayer and YouTube’s Player in this fashion.

Headshot of Andrew

Performance

The Play Store and Jetpack Compose teams worked closely together to make sure Compose could run as fast and be as jank-free as the View framework. Due to how Compose is bundled within the app (rather than being included as part of the Android framework), this was a tall order. Rendering individual UI components on the screen was fast, but end to end times of loading the entire Compose framework into memory for apps was expensive.

One of the largest Compose adoption performance improvements for the Play Store came from the development of Baseline Profiles. While cloud profiles help improve app startup time and have been available for some time now, they are only available for API 28+ and are not as effective for apps with frequent (weekly) release cadences. To combat this, the Play Store and Android teams worked together on Baseline Profiles: a developer-defined, bundled profile that app owners can specify. They ship with your app, are fully compatible with cloud profiles and can be defined both at the app-level of specificity and library-level (Compose adopters will get this for free!). By rolling out baseline profiles, Play Store saw a decrease in initial page rendering time on its search results page of 40%. That’s huge!

Re-using UI components is a core mechanic of what makes Compose performant for rendering, particularly in scrolling situations. Compose does its best to skip recomposition for composables that it knows can be skipped (e.g. they are immutable), but developers can also force composables to be treated as skippable if all parameters meet the @Stable annotation requirements. The Compose compiler also provides a handy guide on what is preventing specific functions from being skippable. While creating heavily re-used UI components in Play Store that were used frequently in scrolling situations, we found that unnecessary recompositions were adding up to missed frame times and thus jank. We built a Modifier to easily spot these recompositions in our debug settings as well. By applying these techniques to our UI components, we were able to reduce jank by 10-15%.

Recomposition visualization Modifier in action

Recomposition visualization Modifier in action. Blue (no recompositions), Green (1 recomposition).

Another key component to optimizing Compose for the Play Store app was having a detailed, end-to-end migration strategy for the entire app. During initial integration experiments, we ran into the Two Stack Problem: running both Compose and View rendering within a single user session was very memory intensive, especially on lower-end devices. This cropped up both during rollouts of the code on the same page, but also when two different pages (for example, the Play Store home page and the search results page) were each on a different stack. In order to ameliorate this startup latency, it was important for us to have a concrete plan for the order and timeline of pages migrating to Compose. Additionally, we found it helpful to add short-term pre-warming of common classes as stop-gaps until the app is fully migrated over.

Compose unbundling from the Android framework has reduced the overhead in our team directly contributing to Jetpack Compose, resulting in fast turnaround times for improvements that benefit all developers. We were able to collaborate with the Jetpack Compose team and launch features like LazyList item type caching as well as move quickly on lightweight fixes like extra object allocations.

Headshot of Jon

Looking Ahead

The Play Store’s adoption of Compose has been a boon for our team’s developer happiness, and a big step-up for code quality and health. All new Play Store features are built on top of this framework, and Compose has been instrumental in unlocking better velocity and smoother landings for the app. Due to the nature of our Compose migration strategy, we haven’t been able to measure things like APK size changes or build speed as closely, but all signs that we can see look very positive!

Compose is the future of Android UI development, and from the Play Store’s point of view, we couldn’t be happier about that!

App Excellence Summit 2022

Posted by The Google Play Team

ALT TEXT GOES HERE 

Did you know that 54% of users who left a 1-star review in the Play Store mentioned app stability and bugs? *

To help product managers and business decision makers understand how high quality app experiences drive business growth and what tools they can use to make sound business and technical decisions, we are hosting our first Android App Excellence Summit in just a few weeks! Join us on April 12 to get the knowledge needed to build high quality Android Apps and scale your business.

Tune in on April 12 at 9 AM Pacific to join the virtual fireside chat and in-depth product sessions. After our fireside chat, we’ll be releasing sessions focused on;

  • Achieving quality with the Play Console: What devices should you build for? How can you track issues? Which countries should you target next? Learn how to use the Google Console’s Reach and devices dashboard for foundational questions like minspec and country targeting, including new features for apps that monetize on Google Play.
  • Improving Developer Productivity: The developer productivity best practices can help you spend less time in maintenance and more time working on new features to delight users, improve your monetization, and achieve business success. Learn the best tools and recommendations to accelerate your development of high-quality apps.
  • Better together: Did you know that in 2021 the average US household had 25 connected devices? That’s twice as many since 2019. Learn how Android is making the ecosystem of devices more helpful, what users expect from your apps and how to optimize them across form factors.
  • And more!

We’re excited to bring you the latest announcements, insights, and best practices at our first Android App Excellence Summit.

Register today to save your spot and follow our Twitter channel and join the conversation by using #AppExcellenceSummit.

-------------------

* Source: Google Play internal data, May 2021.

Happening now! #TheAndroidShow: Tablets, Jetpack Compose & Android 13

Posted by Florina Muntenescu & Huyen Tue Dao, Co-Hosts of #TheAndroidShow

We’re just about to kick off another episode of #TheAndroidShow, you can watch here! In this episode, we’ll take you behind-the-scenes with Jetpack Compose, Android 13 and all of the updates to Android tablets. If you haven’t already, there’s still time to get your burning Android tablet questions answered from the team, using #AskAndroid. We've assembled a team of experts ready to answer your questions live!


First, we go behind-the-scenes with Jetpack Compose

First up in #TheAndroidShow, we’ll be discussing Jetpack Compose, Android’s modern, native UI toolkit. Last month, we released version 1.1 of Jetpack Compose, which contains new features like improved focus handling, touch target sizing, ImageVector caching, and support for Android 12 stretch overscroll. Compose 1.1 also graduates a number of previously experimental APIs to stable and supports newer versions of Kotlin. In #TheAndroidShow, we’ll take you behind-the-scenes in the world of animations with one of the engineers who helps build them, Doris Liu. And then we hear from Twitter about how Compose helps them build new features in half the time!


Next: the world of tablets, including the 12L feature drop, now in AOSP

Next up, we’ll jump into the world of tablets, following the big news from earlier this 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. There are over 250+ million large screen Android devices, and 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.

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.


Tune in now!

Finally, we wrap up the show with a conversation with the director for Android Developer Relations, Maru Ahues Bouza, where we talk about Android 13 as well as some of the broader themes you’ll continue to see from Android later this year.

It’s all happening right now on #TheAndroidShow - join us on YouTube!

Freeing up 60% of storage for apps

Posted by Lidia Gaymond and Vicki Amin, Product Managers at Google Play

One of the main reasons users uninstall apps is to free up space. To prevent unnecessary uninstalls and help users get more out of their devices, we started working on a new feature that would enable app archiving.

Archiving is a new functionality that will allow users to reclaim ~60% of app storage temporarily by removing parts of the app rather than uninstalling it completely. An archived app will remain on the device and can easily be restored to the latest available compatible version, whilst preserving the user data.

With the release of the upcoming version of Bundletool 1.10, we are taking the first step toward making archiving available to all developers using App Bundles. For apps built with the Android Gradle Plugin 7.3, we will start generating a new type of APK - archived APKs. Archived APKs are very small APKs that preserve user data until the app is restored. While we will start creating archived APKs now, they won’t be functional until the archiving functionality is launched to consumers later in the year.

Once launched, archiving will deliver great benefits to both users and developers. Instead of uninstalling an app, users would be able to “archive” it - free up space temporarily and be able to re-activate the app quickly and easily. Developers can benefit from fewer uninstalls and substantially lower friction to pick back up with their favourite apps.

As before, all APKs generated will be available to download and inspect through Generated APKs API or in Play Console under App Bundle Explorer. Since the functionality is open source, developers will be able to inspect the code, and other app stores can benefit from it too.

If you want to opt-out of the generation of archived APKs, you can modify the build.gradle file of the project:

android {
    bundle {
        storeArchive {
            enable = false
        }
    }
}

Alternatively, if you are not using Gradle to build your apps, you can opt-out with a new option in the BundleConfig:

{
  "optimizations": {
    "storeArchive": {
      "enabled": false
    }
  }
}

Keep an eye out for more information about app archiving on the Android Developers blog.

Keeping Google Play safe with our key 2022 initiatives

Posted by Krish Vitaldevara Director, Product Management, Play and Android Trust & Safety

Safety illustration 

Keeping Google Play safe for users and developers remains our top priority. Over the past year, we’ve partnered with developers to ensure their apps are safe. We helped developers to protect their apps, prepare to share their data safety practices with users, and collaborate on building more private advertising technology. We also continued investing in machine-learning detection and enhanced app review processes to stop apps with abusive or malicious content before anyone can install them.

We also realize that it can be challenging for developers to keep up with the pace of change in this evolving privacy and security landscape. We’ve been mindful to give developers clearer updates, more time for substantial changes, and more helpful information through Inbox Console Messages, global webinars, and additional education resources. Today, we’re excited to share more about what’s ahead in 2022 to give you plenty of time to prepare.

What we look forward to this year

Giving everyone a clear way to understand an app’s data safety practices

Developers want to explain data safety to users in a clear and simple way. In the upcoming Data safety section in your app’s Play store listing, you can share how your app collects, shares, and protects user data. Users told us that they value having this information to help them decide if an app is right for them. They’ll start to see the Data safety section in Google Play store in late April, so make sure to submit your Data safety form soon. Completed Data Safety forms will be required for all app updates starting July 20.

Building a more privacy-friendly approach to advertising

We recently announced that we’re expanding the Privacy Sandbox initiative to Android. We’re working on innovative solutions to improve user privacy, while continuing to support key mechanisms that developers rely on to build their businesses and provide access to free apps for everyone. We’re building this technology in close collaboration with developers. Join our email newsletter to stay updated.

Protecting developers' apps from privacy and fraudulent activity

Last fall, we started rolling out the new Play Integrity API to help you protect their games and apps and ensure that users have the intended experience that you designed. Now, everyone has access to this new API, making it easier to detect suspicious traffic and respond faster to issues like fraud and cheating. We've built this in a future-forward way so that you can easily get new features with little build time required to upgrade. Learn how to set it up for your apps here.

Helping developers navigate SDKs

Developers shared that they want faster communication from SDK providers about critical updates, so last year we gave SDK providers a way to notify you about urgent issues in your Google Play Console. You’ve also shared that you want to learn more about an SDK’s safety and reliability to avoid wasting build time or exposing users to unsafe practices. In a few months, we’ll start sharing information like an SDK’s adoption levels, its retention rate, and the runtime permission it uses to help you choose the right SDK for your business and users.

Enhancing protections for kids and families

Last year, we continued to refine our advertising restrictions and parental control requirements to further enhance privacy and safety for kids. Eligible developers can now add a badge to their upcoming Data safety section, highlighting that they’re committed to following our Families policy. You’ll also see continued policy updates this year designed to help protect kids' safety and privacy. Join our policy webinars or watch our PolicyBytes to stay updated.

Responsible Data Collection and Use

Developers should only collect and use the data required for app functionality and improvement. For practical tips on this front, you can view our best practices guide. This year, we’re continuing to align permissions more closely with the appropriate use cases. We’re also in active conversations with developers about ways to mitigate risks from apps that leverage APIs in older Android OS versions. Stay tuned to our policy update emails, as we’ll share more soon.

Thank you for your partnership in making Google Play a safe and trustworthy platform for everyone.

Google for Games Developer Summit returns March 15

Posted by Greg Hartrell, Product Director, Games on Play/Android

Image with Google for Games castle, rocket, volcano, and racetrack

With over three billion players showing strong engagement worldwide, the games market continues to remain resilient and grow beyond expectations. As we look ahead this year, the influx of new and returning players creates a great opportunity for developers to scale their games businesses.

The Google for Games Developer Summit returns virtually on March 15, 2022 at 9AM Pacific. From mobile to cloud, learn about our new solutions for game developers that make it easier to build high-quality games and reach audiences around the world.

Join us for the keynote at 9AM Pacific followed by over 20 developer sessions on-demand. We’ll share deep-dives and updates on the Android Game Development Kit, Google Play Games beta on PC, Play Asset Delivery, Play Console, and more. The summit is open for all. Check out the full agenda today at g.co/gamedevsummit.

Discontinuing Kotlin synthetics for views

Posted by Márton Braun, Developer Relations Engineer


ALT TEXT GOES HERE 

Synthetic properties to access views were created as a way to eliminate the common boilerplate of findViewById calls. These synthetics are provided by JetBrains in the Kotlin Android Extensions Gradle plugin (not to be confused with Android KTX).

In November 2020, we announced that this plugin has been deprecated in favor of better solutions, and we recommended removing the plugin from your projects. We know many developers still depend on this plugin’s features, and we’ve extended the support timeframe so you have more time to complete your migrations.

We are now setting a deadline for these migrations: the plugin will be removed in Kotlin 1.8, which is expected to be released by the end of 2022. At that time, you won’t be able to update your project to newer Kotlin versions if it still depends on the Kotlin Android Extensions plugin. This means that now is the time to perform the necessary migrations in your projects.

Instead of synthetics, we recommend using View Binding, which generates type-safe binding classes from XML layout files. These bindings provide convenient access to view references and they work safely for layouts with multiple configurations. See the migration guide for detailed instructions on how to adopt View Binding. If you encounter any issues, you can report a bug on the Issue Tracker.

When building new features, consider using Jetpack Compose, Android's modern UI toolkit. Layouts built with Compose are declarative Kotlin code, eliminating the need to work with view references.

Another feature included in the plugin is Parcelize, which helps you create parcelable classes. Parcelize is now available in the standalone kotlin-parcelize plugin with unchanged functionality. To get up and running with the new plugin, check out the Parcelize documentation page.

If you’re still using the Kotlin Android Extensions Gradle plugin, kick off your migration in time so that you can keep upgrading to new Kotlin releases in the future. This will enable you to use the latest language features and take advantage of tooling and compiler improvements.

Write better tests with the new testing guidance

Posted by Jose Alcérreca, Android Developer Relations Engineer

Blue illustration with Android phone 

As apps increase in functionality and complexity, manually testing them to verify behavior becomes tedious, expensive, or impossible. Modern apps, even simple ones, require you to verify an ever-growing list of test points such as UI flows, localization, or database migrations. Having a QA team whose job is to manually verify that the app works is an option, but fixing bugs at that stage is expensive. The sooner you fix a problem in the development process the better.

Automating tests is the best approach to catching bugs early. Automated testing (from now on, testing) is a broad domain and Android offers many tools and libraries that can overlap. For this reason, beginners often find testing challenging.

In response to this feedback, and to accommodate for Compose and new architecture guidelines, we revamped two testing sections on d.android.com:

Training

Firstly, there is the new Testing training, which includes the fundamentals of testing in Android with two new articles: What to test, an opinionated guide for beginners, and a detailed guide on Test doubles.

Faking dependencies in unit tests

Faking dependencies in unit tests


After providing an overview of the theory, the guide focuses on practical examples of the two main types of tests.

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.