UFO²

UFO²

Microsoft · Coding · Other

UFO² is Microsoft's open-source Windows desktop agent. It turns plain-language requests into multi-app workflows, mixing native APIs with GUI control.

Interface preview of UFO²

About UFO²

What Is UFO²

UFO² is an open-source agent platform from Microsoft Research for Windows. It reads a request in everyday language and carries it out across the apps on your machine, from Excel and Outlook to third-party tools. Microsoft calls the design a desktop AgentOS, meaning the agent works at the system level rather than as one script tied to one program.

The project started as UFO, a UI-focused agent built on GPT-4V, and UFO² (sometimes written UFO2) is the second version. The step up is depth. Instead of only taking screenshots and clicking, UFO² talks to Windows directly through UI Automation, Win32 and COM, so it can call a native API when one exists and fall back to clicks and keystrokes when it doesn't. Microsoft says this makes it faster and steadier than pure screen-based agents, and the project is fully open under the MIT license.

The tradeoffs matter if you plan to run it. UFO² needs Python 3.10 or newer and runs on Windows 10 and above, so it isn't a click-to-install consumer app, and you bring your own model credentials, which means an API bill on top of setup time. It's built for people who want to automate their own desktop and are willing to configure it.

Getting Started

  1. Clone the Microsoft UFO repository from GitHub and install the requirements with pip on a Windows machine
  2. Copy the agent config template and add your LLM API keys, then pick a model such as GPT-4o or a Qwen build
  3. Launch the app and type a request in plain language, like pulling data from a spreadsheet into a chart
  4. Watch the HostAgent split the job into subtasks and the AppAgents carry them out in the right programs

Product Information

A quick look at UFO²'s pricing, supported platforms, and performance.

Free PlanYes
Paid PlansN/A (bring your own LLM API key)
PlatformWindows
DeveloperMicrosoft
CategoryCoding · Other
Release DateApr 2025
Latest UpdatedApr 2025
Website Visits649.3M
Website Global Rank50
API AvailabilityN/A

Best for

The users, tasks, and scenarios where this tool fits best.

Users

  • Developers and tinkerers
  • Automation engineers
  • Researchers
  • IT and ops staff

Tasks

  • Move data between apps
  • Chain a desktop workflow
  • Automate office chores
  • Prototype a custom agent
  • Benchmark computer use

Scenarios

  • A report that rebuilds itself
  • A cross-app request
  • A cautious rollout
  • A research baseline
  • A custom internal helper

Key features

Deep Windows OS Integration

UFO² hooks into Windows at the system level rather than through the screen alone. It combines UI Automation, Win32 and COM to read the real structure of an interface, including which control is a button and which is a text box, instead of guessing from a picture. Microsoft points to Excel as the example: turning table data into a chart can be one API call, where a traditional RPA tool simulates several mouse clicks. That depth is what earns the AgentOS label.

HostAgent and AppAgent Architecture

The platform splits the work across two kinds of agent. A central HostAgent reads the goal, breaks it into ordered subtasks, launches the programs it needs and coordinates the run through a state machine. Each running program gets its own AppAgent, a specialist that knows that app's interface, APIs and domain knowledge. This split keeps the system modular: a new program means a new AppAgent, not a rewrite of the core.

Hybrid GUI and API Execution

UFO² decides how to act, not just what to do. When an app exposes a native API, the agent calls it for speed and accuracy. When it doesn't, the agent falls back to mouse and keyboard actions. This mixed approach covers both standard and non-standard interfaces, which is where screen-only agents tend to fail. It's the difference between a tool that works on well-behaved apps and one that keeps working when an interface is rough.

Hybrid Control Detection

Reading an interface reliably is the hard part of desktop automation, so UFO² fuses two methods. It uses Windows UI Automation for structured controls and adds vision-based parsing for anything UIA misses, like custom or canvas-drawn elements. The hybrid pipeline supports both standard and non-standard interfaces, and Microsoft credits it with better stability when the layout isn't tidy. It's the layer that decides what's actually on screen before the agent acts.

Speculative Multi-Action Planning

Every step in a typical agent means another round trip to the language model, and that adds up. UFO² bundles several predicted actions into a single LLM call and validates them against the live interface state before running them. Microsoft reports up to 51 percent fewer queries with this method, which cuts both latency and cost. For anyone paying per token, that saving is a real part of the pitch, not a footnote.

Continuous Knowledge Substrate

UFO² keeps a knowledge base it can draw on while it works. It blends offline app documentation, online search, user demonstrations and past execution traces into a vector store and retrieves the relevant pieces on the fly. The result is an agent that leans on what it has seen before rather than starting cold each time, in the same way a person learns a program by using it. Microsoft frames this as the foundation for agents that improve over time.

Picture-in-Picture Desktop

Running an agent on your own desktop usually means losing control of the mouse. On Windows, UFO² addresses this with a Picture-in-Picture desktop: automation runs in an isolated virtual desktop while you keep using your main screen and input devices. Microsoft lists this as coming soon in the current documentation, so it's on the roadmap rather than shipping today. Once it lands, it removes one of the biggest reasons people hesitate to let an agent drive their machine.

Pros and cons

Pros

  • Largely open source under the MIT license, so you can read the code, run it and build on it
  • Calls native Windows APIs through UIA, Win32 and COM, which is faster and steadier than screen-only clicking
  • A hybrid GUI-and-API approach handles both standard and non-standard interfaces
  • Speculative multi-action planning cuts language model calls by up to 51 percent, lowering latency and cost
  • Backed by a published Microsoft Research paper and an active GitHub project with thousands of stars

Cons

  • Needs Python 3.10 or newer on Windows 10 and above, and a manual install, so it isn't a one-click app and takes time to configure
  • You bring your own LLM API keys and pay for the model calls yourself, which adds an ongoing cost
  • Picture-in-Picture, which keeps automation off your main desktop, was still listed as coming soon in the documentation
  • Success depends on how well a given app exposes its controls, so results vary across programs and interfaces

Frequently asked questions

UFO² is an open-source desktop agent from Microsoft Research for Windows. It takes a request in plain language and carries it out across multiple apps, using native Windows APIs when they exist and GUI actions when they don't. Microsoft describes it as a desktop AgentOS rather than a single-app script.