Skip to main content
Mobile-use can capture detailed local traces to help you debug and understand task execution.
Hosted Platform tracing and GIF upload have been removed. Keep traces locally and see the migration guide.

Overview

Local Traces

Screenshots and action logs saved to your local filesystem

Trace Artifacts

Keep screenshots, steps, and generated GIFs in storage you control

How It Works

How it works:
  • When record_trace=True, a GIF is created locally from screenshots.
  • The local trace remains in storage you control.

Local Trace Recording

Enable trace recording to save screenshots and action logs locally.

Basic Usage

Custom Path

What Gets Saved

Local traces include:
  • trace.gif: An animated GIF showing the entire execution. It’s a compilation of screenshots taken after each agent step.
  • steps.json: A compilation of the agent’s thoughts and reasoning during the run, along with timestamps.

Configuration Reference

Task Request Parameters

bool
default:true
Controls local trace creation. Set to False to disable trace recording.
Path
Local directory to save trace files. Defaults to system temporary directory.

Example

Console Output


Troubleshooting

Trace Creation Failed

If the GIF is not created, check:
Maximum GIF size is 300MB. Very long-running tasks (+1h) may exceed this limit. Reduce max_steps in your task configuration or split into multiple shorter tasks.

Verify Trace Creation

Check the console output for the local trace path:
If you see this message, open the directory to inspect the trace.

Missing Local GIF

If the GIF doesn’t appear in the trace directory:
  1. Check task status - GIF generation happens after task completion
  2. Verify record_trace=True - Confirm tracing was not disabled
  3. Check console for errors - Look for trace creation failures

Best Practices

Tracing is enabled by default for easy debugging. Disable it when processing sensitive data or running many tasks in production:

Next Steps

Task Request Builder

Explore all task configuration options

Troubleshooting

Common issues and solutions

Local Quickstart

Configure local task execution and tracing