What is CSS Safe Area Insets Generator?
Safe-area insets are CSS environment variables that help keep content away from phone notches, rounded screen corners, home indicator areas, and other display cutouts. They are useful for mobile web apps, fixed headers, sticky bottom bars, and full-bleed layouts.
How to use this tool
- Choose whether you want to generate padding, margin, or inset rules.
- Set a fallback value for browsers and screens that do not need special safe-area spacing.
- Enter the selector that should receive the safe-area spacing.
- Copy the meta viewport tag and CSS into your page, then test on a mobile device or simulator.
What you can use it for
- Keep fixed headers and bottom bars away from screen cutouts.
- Add safe padding to mobile web apps.
- Create reusable CSS variables for safe-area spacing.