Flutter: A RenderFlex overflowed by x pixels on the right/bottom
A Row or Column’s children need more space than available, so Flutter draws the yellow-black overflow stripes.
Seen on:
Flutter
Meaning
Long text in a Row, fixed-size widgets on small screens, or a Column taller than the screen (e.g. when the keyboard opens) cause it. Make children flexible or scrollable.
Common causes
- Long text/widgets in a Row without Expanded/Flexible
- Column taller than the screen
- Keyboard reducing available height
- Fixed sizes not adapting to small devices
⚡ Quick fix
- Wrap the child in Expanded/Flexible (and set overflow on Text)
- Use SingleChildScrollView or ListView for tall content
- Use LayoutBuilder/MediaQuery for responsive sizes
Detailed fix by platform
Dart
- dart
Row(children: [ const Icon(Icons.info), Expanded(child: Text(longText, overflow: TextOverflow.ellipsis)), ])
How to diagnose
- Widget — Which Row/Column (inspector)?
- Direction — Right (Row) or bottom (Column)?
🔧 Still not fixed?
Many errors look alike. If the steps above didn’t solve it, one of these is probably what you’re facing:
Similar errors
- measured with an infinity maximum height Jetpack Compose: Vertically scrollable component was measured with an infinity maximum height constraints, which is disallowed
- Null check operator used on a null value Dart/Flutter: Null check operator used on a null value
- setState() called after dispose() Flutter: setState() called after dispose(): _MyState#1a2b3 (lifecycle state: defunct, not mounted)
Other ways to find it
🧠 Still stuck? Analyze your error
Paste the full message, response headers or stack trace — we'll detect the platform and point to the most likely cause.
Was this page helpful?
Report a correction or suggest an improvement
Last updated 7 Oct 2026