# 5 tips for speeding up your XR dev workflows with Unity CLI

> Source: <https://unity.com/blog/5-tips-for-speeding-up-your-xr-dev-workflows-with-unity-cli>
> Published: 2026-09-16 23:53:45.034502+00:00

Following the launch of [Unity CLI](https://unity.com/blog/meet-the-unity-cli), we’ve seen a lot of enthusiasm and interesting use cases. We’ve also created an introductory [video tutorial](https://www.youtube.com/watch?v=DgNrgZeJOxQ) to help you get started.

In a [previous post](https://unity.com/blog/5-tips-for-using-github-copilot-with-unity), we featured Stacey Haffner, former Principal Developer Advocate at Microsoft and indie game creator, who shared her top workflow recommendations for GitHub Copilot.

For today's article, we caught up with [Dilmer Valecillos](https://x.com/dilmerv), Developer Advocate at Meta, Founder of Learn XR, and creator of a popular [YouTube channel](https://www.youtube.com/@dilmerv) focused on XR and game development. **We asked him: What are five key ways you integrate Unity CLI into your favorite tools and XR workflows?**

Let’s dig into Dilmer's tips:

## Tip 1: Leverage the new Unity CLI and pipeline package over the MCP

"As an early adopter of technology, I'm continuously searching for ways to streamline my XR workflows, and I've been working with the Unity MCP server since its release. My recommendation, however, is to skip the MCP and use the new Unity CLI and pipeline package. The CLI features its own built-in MCP server that utilizes the same protocol. That means your MCP client can connect effortlessly, just as it currently does. This new CLI and its MCP also gives you several advantages. The most important to me, is that it offers dramatically faster iteration times by leveraging the Roslyn compiler for code evaluation. It eliminates the need for Editor recompiles and domain reloads, and it extends support to target runtime environments alongside the Editor. The setup process is straightforward, and I recently published a video demonstrating the step-by-step walkthrough you can watch [here](https://www.youtube.com/watch?v=wfvCkdNcdvM). Where the agentic workflows shine is the combination with Pipeline package though, which allows you to communicate with the Editor."

**Installing CLI + the Pipeline package**

We won’t go through all the details of installing but you can find those here:

[https://docs.unity.com/en-us/unity-cli](https://docs.unity.com/en-us/unity-cli)

## Tip 2: Familiarize yourself with the basic commands

“You can save time by familiarizing yourself with some of the basic CLI commands. You don’t need to memorize them all, but knowing a few basics saves time because you can skip the UI. Here are a few of the basic commands I use all the time.”

Let me start with:

`unity command --changelog`

“Because the CLI updates frequently, keeping an eye on the changelog is helpful. It summarizes recent changes, making it easy to understand what new features are available as the CLI develops. As someone who wants to make use of the latest features, that’s something I look out for. “

`unity command eval "return UnityEditor.EditorApplication.isPlaying;"`

The `eval` command is probably the most powerful command you find. When the Unity Pipeline package is running inside your Editor, the CLI can compile and run C# snippets live on the main thread via Roslyn. Because there is no project-level recompile and no domain reload, it executes in milliseconds instead of making you wait. You can use this to run automated setup scripts, query editor states, or even execute C# script files from your disk using unity command eval_file "path/to/script.cs"

`unity install 6000.5.0f1 -m android android-sdk-ndk-tools --cm --accept-eula --yes`

Another simple tip is that you can use specific parameterized commands. Take the install command as an example: because I like to run the latest version of Unity, I often need to install it. As an example with the install command, you can queue up commands as in the example

`unity install 6000.5.0f1 -m android android-sdk-ndk-tools --cm --accept-eula --yes`

Another simple tip is that you can use specific parameterized commands. Take the install command as an example: because I like to run the latest version of Unity, I often need to install it. As an example with the install command, you can queue up commands as in the example above.

**Unity command-line interface (CLI) reference**

Full reference guide is available here:

https://docs.unity.com/en-us/unity-cli/unity-cli-reference

## Tip 3: Try out different LLMs

“While sticking to a single tool works for many developers, I prefer experimenting with various options. For us at Meta it’s important to bring the tools you prefer working with directly into your primary editors like Cursor, Claude Code, and Muse Code. Because the Unity CLI offers support for multiple clients, be sure to link it with your preferred LLM. I’m currently using a mix of Claude Code and Codex, but I regularly switch things up. Another workflow tip is to mix tools by using one LLM for authoring and another for code reviews.”

## Tip 4: Get to a working Quest build faster with Meta’s AI tooling

“General coding assistants are surprisingly confident about VR, and surprisingly often wrong. Ask one about hand tracking or how to bring your draw calls down and you’ll usually get an answer that’s right for mobile and wrong for Quest. It’s not really the model’s fault. It doesn’t have our docs, and it can’t see your headset. That’s the gap I use the [Meta VR CLI](https://developers.meta.com/horizon/documentation/unity/ts-ai-tooling-overview/#hzdb-horizon-debug-bridge) to close.”

The Meta VR CLI gives your assistant both of those things, and it ships with its own MCP server so it drops into whichever client you’re already using, whether that’s Codex, Cursor, Claude Code, Gemini, or VS Code:

`metavr mcp install claude-code    # or cursor, vscode, project`

“Once it’s connected, the answers change. Ask about passthrough camera access and it pulls the current documentation instead of guessing from whatever it learned a year ago. And because it can reach the device, it stops at suggestions a lot less often. It installs the build, tails logcat while I reproduce the bug, and screenshots what I’m actually seeing in the headset rather than what the Game view thinks I’m seeing. That last one has saved me more headset on-and-off cycles than anything else in my setup.”

Two more are worth wiring in before you write a line of code. The [Project Setup Tool](https://developers.meta.com/horizon/documentation/unity/unity-upst-overview/) checks your project against what Quest actually requires and fixes what’s misconfigured, so you find out now instead of at build time. And the [Meta Asset Library](https://developers.meta.com/horizon/documentation/unity/unity-asset-library-overview/) puts 1.5 million royalty-free 3D assets, with LODs already authored, inside the SDK, and your agent can search it directly through the Meta VR CLI, so you’re never blocked on placeholder art just to test an idea.

## Tip 5: Let agents assist your performance profiling

“Performance is the part of VR development nobody warns you about. You build something that feels great in the Editor, then you run it on your device and watch it fall apart. And the loop for fixing it has always been very involved: capture a trace, load it into Perfetto, then scroll around trying to work out which of those thousands of slices is the one costing you frames. I’ve lost whole afternoons that way.”

That’s the loop the new `perf` commands in the Meta VR CLI are meant to break. You can capture from a connected Quest just by describing what you want, like “take a 15-second capture with GPU data,” and the agent runs the capture and reads the result back, surfacing frame-time spikes and CPU/GPU bottlenecks in seconds instead of after an afternoon of scrolling.

`metavr perf capture --mode full --duration 15000 --app com.mycompany.myvrapp --output my_vr_trace`

“The point isn’t that AI finds something you couldn’t have found yourself. It’s that reading a trace is exactly the kind of work it’s good at: a lot of unstructured data, and patterns you’d otherwise hunt for by hand. It gives you those hours back to spend on the actual fix.”

Inside Unity, the Quest [Runtime Optimizer](https://developers.meta.com/horizon/documentation/unity/unity-quest-runtime-optimizer) comes at the same problem from the other direction. Bottleneck analysis parses your captured runtime data, flags what’s going wrong, and suggests what to try; “What If” analysis lets you A/B individual GameObjects to see what each one actually costs you. And if you’d rather stay hands-on, the tools you already know are still there and still good: OVRMetrics for in-headset numbers, the Meta Quest fork of RenderDoc for frame debugging, and our Perfetto improvements alongside Unity’s own profiler.

“However you get there, the goal is the same: less time proving there’s a problem, more time fixing it.”

If you’re interested in the topic of performance optimization, we highly recommend our ebook on the topic. You can get the ebook for free [here](https://unity.com/resources/mobile-xr-web-game-performance-optimization-unity-6).

### Follow Dilmer

If you found these tips helpful and would like to learn more, make sure to connect with Dilmer on [X](https://x.com/dilmerv) or [LinkedIn](https://www.linkedin.com/in/dilmerv/) and subscribe to his [YouTube channel](https://www.youtube.com/@dilmerv). To learn more about CLI check out our official documentation [here](https://docs.unity.com/en-us/unity-cli).
