Posted by Paris Hsu – Product Supervisor, Android Studio
The subsequent wave of innovation is right here with Android Studio Narwhal Characteristic Drop. We’re thrilled to announce that Gemini in Android Studio’s Agent Mode is now out there within the secure launch, able to deal with your most advanced coding challenges. This launch additionally brings highly effective new instruments for XR improvement, continued high quality enhancements, and key updates to reinforce your productiveness and provide help to construct high-quality apps.
Dive in to be taught extra about all of the updates and new options designed to supercharge your workflow.

Develop with Gemini
Check out Agent Mode
Transcend chat and assign duties to Gemini. Gemini in Android Studio’s Agent Mode is a strong AI function designed to deal with advanced, multi-stage improvement duties. To make use of Agent Mode, click on Gemini within the sidebar after which choose the Agent tab. You possibly can describe a high-level objective, like including a brand new function, producing complete unit exams, or fixing a nuanced bug.
The agent analyzes your request, breaks it down into smaller steps, and formulates an execution plan that makes use of IDE instruments, similar to studying and writing recordsdata and performing Gradle duties, and might span a number of recordsdata in your undertaking. It then iteratively suggests code adjustments, and also you’re all the time in management—you’ll be able to overview, settle for, or reject the proposed adjustments and ask the agent to iterate primarily based in your suggestions. Let the agent deal with the heavy lifting when you deal with the larger image.
After releasing Agent Mode to Canary, we had optimistic suggestions from the builders who tried it. We have been so excited concerning the function’s potential, we moved it to the secure channel sooner than ever earlier than, to be able to get your fingers on it. Attempt it out and tell us what you construct.

At the moment, the default mannequin supplied within the free tier in Android Studio has a shorter context size, which might restrict the depth of response from some agent questions and duties. In an effort to get the very best efficiency from Agent Mode, you’ll be able to carry your personal key for the general public Gemini API. When you add your Gemini API key with a paid GCP undertaking, you’ll then be capable to use the most recent Gemini 2.5 Professional with a full 1M context window from Android Studio. Bear in mind to select the “Gemini 2.5 Professional” from the mannequin picker within the chat and agent enter packing containers.

Guidelines in immediate library
Tailor the response from Gemini to suit your undertaking’s particular wants with Guidelines within the immediate library. You possibly can outline most popular coding kinds, tech stacks, languages, or output codecs to assist Gemini perceive your undertaking requirements for extra correct and personalised code help. You possibly can set these preferences as soon as, and so they’ll be mechanically utilized to all subsequent prompts despatched to Gemini. For instance, you’ll be able to create a rule similar to, “All the time present concise responses in Kotlin utilizing Jetpack Compose.” It’s also possible to set guidelines on the IDE degree for private use throughout initiatives, or on the undertaking degree, which will be shared with teammates by including the .thought folder to your model management system.

Remodel UI with Gemini [Studio Labs]
Now you can remodel UI code throughout the Compose Preview surroundings utilizing pure language, instantly within the preview. This experimental function, out there by Studio Labs, hastens UI improvement by letting you iterate with easy textual content instructions. To make use of it, right-click within the Compose Preview and choose Remodel UI With Gemini. Then enter your pure language requests, similar to “Heart align these buttons,” to information Gemini in adjusting your structure or styling, or choose particular UI parts within the preview for higher context. Gemini will then edit your Compose UI code in place, which you’ll be able to overview and approve.

Immersive improvement
XR Android Emulator and template
Kickstart your prolonged actuality improvement! Android Studio now contains:
- XR Android Emulator: The XR Android Emulator now launches embedded throughout the IDE by default. You possibly can deploy your Jetpack app, navigate the 3D area, and use the Embedded Format Inspector instantly inside Android Studio.
- XR template: Get a head begin in your subsequent undertaking with a brand new template particularly designed for Jetpack XR. This supplies a strong basis with boilerplate code to start your immersive expertise improvement journey immediately.


Embedded Format Inspector for XR
The embedded Format Inspector now helps XR functions, which helps you to examine and optimize your UI layouts throughout the XR surroundings. Get detailed insights into your app’s element construction and establish potential structure points to create extra polished and performant experiences.

Android Accomplice Machine Labs out there with Android Machine Streaming
Android Accomplice Machine Labs are gadget labs operated by Google OEM companions, similar to Samsung, Xiaomi, OPPO, OnePlus, vivo, and others, and increase the choice of gadgets out there in Android Machine Streaming. To be taught extra, see Connect with Android Accomplice Machine Labs.

Optimize and refine
Jetpack Compose preview high quality enhancements
We have made a number of enhancements to Compose previews to make UI iteration sooner and extra intuitive:
- Improved code navigation: Now you can click on on a preview’s title to immediately leap to its @Preview definition, or click on a person element throughout the preview to navigate on to the operate the place it is outlined. Hover states and improved keyboard arrow navigation make transferring by a number of previews a breeze.
- Preview picker: The brand new Compose preview picker is now out there. You possibly can click on any @Preview annotation in your Compose code to entry the picker and simply handle your previews.


K2 mode by default
Android Studio now makes use of the K2 Kotlin compiler by default. This next-generation compiler brings vital efficiency enhancements to the IDE and your builds. By enabling K2, we’re paving the best way for future Kotlin programming language options and an excellent sooner, extra strong improvement expertise in Kotlin.

16 KB web page dimension help
That can assist you put together for the way forward for Android {hardware}, this launch provides improved help for transitioning to 16 KB web page sizes. Android Studio now affords proactive warnings when constructing apps which might be incompatible with 16 KB gadgets. You need to use the APK Analyzer to establish which particular libraries in your undertaking are incompatible. Lint checks additionally spotlight the native libraries which aren’t 16 KB aligned. To check your app on this new surroundings, a devoted 16 KB emulator goal can also be out there within the AVD Supervisor.


Providers compatibility coverage
Android Studio affords service integrations that provide help to and your staff make sooner progress as you develop, launch, and keep Android apps. Providers are always evolving and should turn out to be incompatible with older variations of Android Studio. Subsequently, we’re introducing a coverage the place options that rely upon a Google Cloud service are supported for roughly a yr in every model of Android Studio. The IDE will notify you when the present model is inside 30 days of turning into incompatible so you’ll be able to replace it.

Abstract
To recap, Android Studio Narwhal Characteristic Drop contains the next enhancements and options:
Develop with Gemini
- Gemini in Android Studio: agent mode: use Gemini for tackling advanced, multi-step coding duties.
- Guidelines in Immediate Library: Customise Gemini’s output to your undertaking’s requirements.
- Remodel preview with Gemini [Studio Labs]: Use pure language to iterate on Compose UI.
Immersive improvement
- Embedded XR Android Emulator: Check and debug XR apps instantly throughout the IDE.
- XR template: A brand new undertaking template to kickstart XR improvement.
- Embedded Format Inspector for XR: Debug and optimize your UI in an XR surroundings.
- Android Accomplice Machine Labs out there with Android Machine Streaming: entry extra Google OEM associate gadgets.
Optimize and refine
- Compose preview enhancements: Higher navigation and a brand new picker for a smoother workflow.
- K2 mode by default: Sooner efficiency with the next-gen Kotlin compiler.
- 16KB web page dimension help: Lint warnings, evaluation, and an emulator to organize for brand new gadgets.
- Providers compatibility coverage: Keep up-to-date for entry to built-in Google companies.
Get began
Able to speed up your improvement? Obtain Android Studio Narwhal Characteristic Drop and begin exploring these highly effective new options at present! As all the time, your suggestions is essential to us.
Test recognized points, report bugs, counsel enhancements, and be a part of our vibrant group on LinkedIn Medium, YouTube, or X. Let’s construct the way forward for Android apps collectively!