xRay and Flutter DevTools
Flutter DevTools is the official debugging suite for Flutter, and every Flutter developer should know it. xRay is not a replacement for it. It covers a different part of debugging, for more people on the team. Most teams use both.
What DevTools is for
DevTools connects to one running app through the Dart VM service that flutter run or your IDE starts. It is the right tool for:
- the Flutter Inspector: the widget tree, layout and render objects;
- performance: frame rendering, jank and the CPU profiler;
- memory: allocations, leaks and snapshots;
- stepping through code with the debugger.
What xRay is for
xRay shows the data your app sends, logs and stores, in a desktop app that connects to the app over your local network:
- network calls from Dio,
package:httpanddart:io, with GraphQL, WebSockets, protobuf and Serverpod (Flutter network inspector); - logs with levels, loggers, errors and stack traces (Flutter log viewer);
- SharedPreferences, secure storage and your own stores, which you can edit (storage viewer);
- SQLite and Hive databases from sqflite, drift and hive_ce, which you can query and, when the app allows it, edit;
- the app’s files, and device actions such as dark mode, locale, deep links and simulated pushes.
Where they differ
| Flutter DevTools | xRay | |
|---|---|---|
| Widget tree, layout, performance, memory | Yes | No |
| Network calls | HTTP from dart:io |
Dio, http and dart:io, GraphQL, WebSockets, protobuf, Serverpod |
| Secure storage and your own key-value stores | No | View and edit |
| SQLite and Hive databases | Only through a package’s own DevTools extension | Browse, run SQL, edit when the app allows it |
| Calls, logs and storage on one timeline | No | Yes |
Needs a debugger session from flutter run or an IDE |
Yes | No, connects over the local network |
| Several apps or devices at once | One app per session | Tabs, side by side |
| Hand a whole session to a teammate | No | .xray file with calls, logs and storage |
| Made for testers and product people too | Built for developers | Yes, in 18 languages |
When to reach for which
- A screen renders wrong or drops frames: DevTools.
- A screen shows the wrong data, a request fails, or a tester found a bug on their phone: xRay.
- You need to hand a bug to someone else with everything that happened: export an xRay session.
Try xRay
xRay runs on macOS, Windows and Linux and is free during the alpha. It needs an impaktfull account with approved alpha access.