One App, Many Screens
Your app will run on tiny phones, big tablets, foldables, browsers and desktops. A responsive app adapts its layout to the space it gets.
MediaQuery: Ask About the Screen
SafeArea
SafeArea keeps your content away from the notch, status bar and the home indicator.
LayoutBuilder: Use the Space of the Parent
LayoutBuilder tells you how much space the parent gives you. This is better than the screen size, because a widget may sit in a narrow panel on a wide screen.
| Width (logical px) | Typical device | Layout idea |
|---|---|---|
| Under 600 | Phone | One column, bottom navigation |
| 600 to 900 | Tablet or foldable | Two columns, navigation rail |
| Over 900 | Desktop, big web | Side menu plus content, max width |
A Master-Detail Example
Other Helpful Widgets
| Widget | Use |
|---|---|
Flexible / Expanded | Share available space |
AspectRatio | Keep a width to height ratio, such as 16 / 9 for videos |
FractionallySizedBox | Use a fraction of the parent size |
ConstrainedBox | Set minimum and maximum size |
Wrap | Move items to the next line when full |
OrientationBuilder | Build different UI for portrait and landscape |
Text Scale and Accessibility
Users can make the text bigger in the phone settings. Test your screens with large text, and avoid fixed heights for text containers.
Testing Different Sizes
- Run the app in Chrome and resize the window
- Use the device preview in DevTools
- Test portrait and landscape on emulators
Expanded, Flexible, Wrap and breakpoints.
Conclusion
Responsive design is mostly about flexible widgets and a few breakpoints. Use LayoutBuilder for local decisions and MediaQuery for screen information.

