The hidden switch14 minAnthropic quietly added an experimental Code Mode to Claude Code. Instead of hauling every tool result through your conversation, Claude writes a little JavaScript and only brings back the answer. Here's what it is, where the big savings numbers come from, how to turn it on, and how to test whether it actually helps your work.Read now →

Google Wants to Kill the Chatbot Reply. Its New Protocol Lets AI Answer With Buttons Instead
A2UI 1.0 lets an AI agent reply with a native card, form or button set that your own app draws, on the web, iPhone and Android. A real build shows a 170-character model reply expanding into 6,000 characters of interface, with the sensitive data never touching the model. Here's how it works and whether to adopt it.
Every AI agent has the same awkward moment.
It needs something from you: a date, a choice between three options, a yes or no before it spends money. So it writes the options out in a chat bubble and waits for you to type an answer back. "Reply 1, 2 or 3." It's 2026, and the most advanced software on Earth is still running a text-message phone tree.
Google thinks the reply itself is the problem. On November 11, it released A2UI 1.0, the first stable version of an open protocol that lets an agent answer with a real interface: a card, a form, a date picker, a row of buttons. Your app draws it with its own native components, whether that's React in a browser, SwiftUI on an iPhone or Jetpack Compose on Android.
A hands-on build with the new version shows why developers should pay attention. A single agent drove the same live incident card on a phone and a web app at the same time. The model wrote 170 characters. The user saw a full, interactive interface. And the sensitive numbers on that card never passed through the model at all.
Here's how it works, what changed in 1.0, and whether it's worth adopting now.
The problem with chat as an interface
Chat is a great way to ask for things. It's a terrible way to do most things.
Think about what you actually want when an agent needs input:
- Picking a date → a calendar, not "please type the date in YYYY-MM-DD format."
- Comparing options → a few cards side by side, not three paragraphs.
- Confirming an action → a clearly labeled button, not "type CONFIRM to proceed."
For developers, the obvious workaround has been letting the model generate HTML or JavaScript and rendering it. That's risky. A model that's been hit by a prompt injection could slip a malicious script onto your page. It also looks off-brand and wastes tokens.
A2UI takes a different route.
How A2UI works, in plain English
The core idea fits in one sentence: the agent decides what to show, and each app decides how it looks.
Here's the flow:
- Your app publishes a catalog, a list of trusted components it knows how to draw (cards, text fields, buttons, pickers, charts).
- The agent sends A2UI messages: a JSON description of which catalog components to show and what data goes in them. No HTML. No code.
- Your app's renderer draws those components using its own native UI toolkit.
- When the user taps a button, the renderer hands an action back to the agent.
Three properties fall out of that design:
- It stays on brand. The agent can only use components you registered. The look comes from your CSS or your Swift code, not from the model.
- It's safer. Your app receives data, not code, so an injected agent has no way to sneak a script onto the page.
- It's efficient. Data is kept separate from layout. When one value changes, the app updates just that value instead of rebuilding the screen.
What's new in 1.0
Google describes 1.0 as simpler and stricter. The headline changes:
- A stable protocol. Developers can build on it without expecting breaking changes every month.
- Bidirectional function calls. The agent and the app can call functions on each other. Google's example: a flight or reservation picker that checks availability on the spot.
- Self-correcting errors. If the agent uses a component in a way the catalog doesn't allow, it gets back an error code it can use to fix its own answer.
- Faster screen creation. Creating a new screen now takes one message instead of three, according to developers testing the release.
- Accessibility support and extensions for extra metadata.
Renderers for every major platform
Open-source renderers now draw A2UI with:
- React, Angular and Lit on the web
- Flutter on mobile, web and desktop
- SwiftUI on iOS
- Jetpack Compose on Android (still v0.9.1, with 1.0 "coming soon")
Agent SDKs are available for Python, TypeScript and Dart. Google says companies including Atlassian, Alation, Bloomberg and ByteDance are already building with it.
The token trick: A2UI Express and macros
The most practical upgrade isn't in the protocol. It's in how the model writes it.
A2UI Express
Generating deeply nested JSON that has to match a complex schema is slow and error-prone for language models. Every curly brace costs tokens and adds a chance of failure.
So Google introduced A2UI Express, a compact format the model writes instead. It looks a bit like Python: one statement per line, each assigning a component to a variable. Deterministic code in the SDK then compiles that into the full JSON the apps need.
Google's numbers, from its October engineering post:
- Express uses up to 3x fewer tokens than writing the JSON directly.
- It can cut latency by up to 3x.
- Using a fast "decision model" that picks pre-defined layouts instead of writing text can cut latency by up to 80x.
Express is now the default inference format in the SDKs, and you can swap in Direct JSON or your own format with one argument.
Macros
Macros go further. They're ordinary Python functions on your server, marked with a decorator, that expand into full components after the model is done writing.
Instead of making the model spell out every field of, say, an order-status card, the model writes one call, like OrderStatus("ord_42"). Your server looks up the order and builds the full card.
Google lists four reasons to use them:
- Fewer output tokens and lower latency.
- Consistent layouts, because your code builds the hierarchy.
- Live data from your databases and APIs, keyed by an ID the model supplies.
- New "components" shipped with a server deploy alone, no app update needed.
Macros are currently Python-only, with other languages promised.
Setting it up
The setup is shorter than you might expect.
On the agent side:
- Install Google's A2UI agent SDK.
- Pick a catalog. The basic catalog that ships with A2UI is fine to start.
- Add the SDK's ready-made prompt snippet to your system prompt. It teaches the model the format.
- As the model streams its answer, the SDK parses it into A2UI messages. Send those to your app over whatever connection you already use, such as server-sent events or a WebSocket.
- Optionally, write your own macros as decorated Python functions.
On the app side:
- Install the renderer for your platform (a React package on the web, a Swift package on iOS).
- Create a message processor with the same catalog.
- Feed it the messages from the agent and drop a surface component into your UI.
- When the user presses a button, the processor gives you an action. Send it back to the agent.
That's the whole loop.
The real-world test: one agent, two apps, live incidents
To see whether this holds up outside a demo, one developer built a cross-platform incident manager. The setup:
- A SwiftUI app in the iPhone simulator.
- A React app in the browser.
- A real incident-monitoring dashboard from a commercial observability service.
- A single Python agent running on Gemini, using Google's A2UI agent SDK.
The important detail: both apps only knew A2UI's basic components. There was not a single line of incident-specific code in either app.
Step 1: An incident appears, without the model
The developer created a dummy "checkout" incident from the terminal. Seconds later, a full incident card appeared on the phone and in the browser simultaneously.
The server had spotted the incident on its own and pushed the card through the A2UI pipeline without calling the model at all. That's a useful pattern: not every UI update needs an expensive LLM call.
Step 2: Acknowledge from the browser
In the browser, the developer lowered the severity to 2 and pressed Acknowledge.
The severity picker was bound to A2UI's data model, so the chosen value traveled back to the server inside the action. The server acknowledged the incident through the monitoring service's API, updated its severity and pushed a small data update to both apps. The phone's card changed at the same instant.
In the monitoring dashboard, the incident showed as acknowledged at severity 2, and the timeline confirmed the change came through the API.
Step 3: Investigate from the phone
On the iPhone, the developer pressed Investigate. That sent an action to the agent, which answered with the same card plus the latest log lines from the checkout service.
Here's the number that matters: the model wrote 170 characters of A2UI Express. The server turned that into almost 6,000 characters of A2UI JSON.
You pay for the short version. The server does the heavy lifting.
Step 4: The model never sees your data
Those 170 characters were mostly two macro calls with the incident ID. The macros built the cards on the server.
So the model never saw the error rates, the user counts or the logs. It only saw a list of incident IDs and titles. The real numbers went from the server straight to the apps after the model had answered.
That's a genuinely big deal for anyone handling sensitive data. Your model provider doesn't need to see customer numbers just to show them to your user.
Step 5: Resolve
Finally, resolving the incident from the phone updated the browser and the monitoring dashboard immediately. The service had even generated a short AI postmortem.
The styling footnote
The entire look of the demo came from one CSS file and one Swift file. The agent was never touched to style anything.
The one limitation noticed: basic components can't be colored individually, so every status icon had to be the same color everywhere. If you need that, you'd build custom catalog components.
Three update patterns worth stealing
Look closely at the incident-manager build and you'll find three distinct ways UI changed. Each is a design pattern you can reuse:
- Server push, no model. A new incident arrived and the server built the card itself. Use this for anything event-driven: new orders, alerts, status changes. It's instant and costs zero tokens.
- User action, data-only update. Changing the severity didn't require the model either. The action went to the server, the server called an API, and a tiny data update changed one value on both screens. Use this for edits, approvals and toggles.
- Model-driven response. Only "Investigate" actually needed reasoning, so only that step called the model, and even then the model wrote two short macro calls.
The lesson: a well-built A2UI app calls the model only when judgment is needed. Everything else is plain, fast, deterministic software. That's how you keep agent products both responsive and affordable.
A2UI vs. MCP Apps
If you follow agent tooling, you've heard of MCP Apps, which let tools show interactive UI inside AI assistants. How is this different?
- MCP Apps ship a whole web app into a sandboxed frame inside the assistant.
- A2UI ships only a description of the interface. The host app stays in control of the look.
They aren't rivals. Google says A2UI's web and Flutter renderers work inside MCP Apps, so A2UI screens can appear in assistants that support MCP Apps, such as Claude and Gemini.
Why this matters
A few reasons this is more than a developer convenience.
1. It changes what "talking to an agent" means. If agents answer with native UI, the chat box stops being the product. It becomes one input among many.
2. It's a security improvement, not just a UX one. Separating data from layout, and keeping sensitive values off the model entirely, addresses two of the scariest problems in agent products: injection and data leakage.
3. It's a cost story. Writing 170 characters instead of 6,000 adds up fast across millions of interactions.
4. It fits the industry's direction. Agents are moving from chat into apps, phones and workplaces. (See how Anthropic is pulling apps inside Claude or how Google's Tasks agent works over text and email.) A standard way to render agent output natively is the missing piece.
The risks and the caveats
A2UI is promising, but it's early.
- The Android renderer isn't 1.0 yet. It's at v0.9.1.
- Docs are still catching up with the release.
- The basic components are limited. For a truly custom look, you'll need your own catalog.
- Macros are Python-only for now.
- Standards fights are real. Several companies are pushing their own approaches to agent UI. A2UI's open-source status and MCP Apps compatibility help, but the market hasn't settled.
- Designers lose some control. When an agent composes the screen, the exact layout can vary between turns. Macros and decision models reduce that, but don't remove it.
Should you adopt it?
Yes, try it, if:
- You're already building an agent into a product and users currently type answers to multiple-choice questions.
- You need the same agent to serve web and mobile.
- You handle data you'd rather not send to a model provider.
Wait, if:
- You're Android-first and need a stable 1.0 renderer.
- You need heavily customized visuals and don't have time to build a custom catalog.
A sensible first project: pick one flow where your agent asks for structured input today, like a booking confirmation or an approval step, and rebuild just that with the basic catalog.
FAQ
What is A2UI? An open-source protocol from Google that lets AI agents describe interfaces (cards, forms, buttons) as data, which your app then draws with its own native components.
Is A2UI only for Gemini? No. The agent SDKs work with your choice of model. The demo described here happened to use Gemini.
How does A2UI save tokens? The model writes the compact A2UI Express format, and server-side macros expand short calls into full components. Google says Express alone uses up to 3x fewer tokens than raw JSON.
Is it secure? It's designed to be safer than generating HTML: apps receive data, not code, and agents can only use components in your catalog. You still need normal security practices.
How is it different from MCP Apps? MCP Apps embed a whole web app in a sandbox. A2UI sends only a description of the UI, and the two can work together.
The bottom line
The chatbot reply had a good run. But for anything beyond conversation, text is a clumsy interface, and everyone building agents knows it.
A2UI's bet is simple: let the agent pick what to show, and let the app decide how it looks. Version 1.0 makes that bet stable, cheaper and safer, and the live incident-manager build shows it working across two platforms with zero custom UI code.
It's early, especially on Android. But if you're building an agent into a product, this is the moment to stop making users type "1, 2 or 3."





