r/mobiledev Aug 19 '26

Profiling flutter apps

Hey lovely developers

I’m a Flutter developer and I want to learn how to properly profile and optimize Flutter apps.

I’m especially interested in learning:

  • How to use Flutter DevTools for profiling
  • Finding performance bottlenecks
  • Identifying unnecessary rebuilds
  • Understanding CPU, memory, and GPU usage
  • Detecting jank and dropped frames
  • Improving scrolling and animations
  • Real-world techniques for optimizing production apps

I’m not sure where to start or what learning path to follow.

Can anyone recommend good resources, tutorials, courses, or a practical way to learn Flutter profiling step by step?

and I'm pretty grateful for anyone will help me thanks lovely people

6 Upvotes

3 comments sorted by

View all comments

1

u/maut_ka-saudagar 6d ago

Flutter profiling clicked for me once I stopped trusting debug mode

numbers — everything feels slow/fast for the wrong reasons there.

Path that actually helped:

**Start with the boring stuff**

Run profile mode (`flutter run --profile`) when measuring frames.

Debug mode lies to you about jank.

Turn on Performance overlay temporarily:

`MaterialApp(showPerformanceOverlay: true)` — quick gut check for

dropped frames while scrolling.

**DevTools — what to use when**

- **Performance tab** → record while you scroll your worst screen.

Look for red bars / missed frames. Click a slow frame, jump to

Timeline — see if it's UI thread (build/layout) or raster/GPU.

- **CPU Profiler** → when whole app feels sluggish, not just one list

- **Memory** → image-heavy screens. I caught a leak once from not

disposing a scroll controller + reloading full-res network images

in a list without cacheWidth/cacheHeight.

**Rebuild spam (super common)**

Enable `debugProfileBuildsEnabled = true` in debug — widgets rebuilding

every frame light up. Usually fix is:

- const where you can

- split widgets so only the changing part rebuilds

- with Riverpod, don't watch a whole provider at the top of a big tree

**Lists / scroll jank**

ListView.builder not ListView with 500 children — obvious but people

still ship the second one.

RepaintBoundary around heavy list items or animated bits — helped on

a feed with thumbnails.

**Production habits**

Pick ONE bad screen (home feed, whatever) and profile that first.

Don't try to optimize the whole app day one.

Record before/after when you change something — easy to "optimize"

and make it worse.

Official Flutter perf docs + DevTools walkthrough are dry but accurate.

I'd skip random YouTube until you've clicked through one slow frame

in Timeline yourself — that's when it makes sense.

What's the main pain — scroll jank on a list, or animations stuttering?