r/iOSProgramming • • Oct 25 '26

Question Looking for a way to save screenshots without the clock and the top status bar

Post image

I'm trying to save screenshots from the simulator, but I can't find a way to do it without the clock and battery indicators. Is there any method you know of where you could hide these from screenshots?

I've been manually erasing them in Figma, but I'm wondering if there's a better way.

19 Upvotes

20 comments sorted by

6

u/fakkeldij Oct 25 '26

The status bar is OS chrome drawn over your app, so there's no way to remove it from a screenshot afterwards, but you can override it to a clean fixed state before you capture, the same trick fastlane's snapshot tool uses for App Store screenshots.

xcrun simctl status_bar booted override --time "9:41" --batteryState charged --batteryLevel 100 --cellularBars 4 --wifiBars 3

Run that in Terminal right before you take the screenshot and the clock, signal and battery show a clean state instead of whatever's actually on your Mac. xcrun simctl status_bar booted clear resets it afterwards.

2

u/prolikewhoa Oct 25 '26

Thanks. I was trying this one but it shows a clean 9:41 and a full battery. But I wanted to completely remove them so I can re-use them for Android. I think Figma’s erase feature may the the only way right now. And it’s because I have graphics going into the safe area.

2

u/HappyTuesdayR1S Oct 25 '26

This is the way.

13

u/quizbeat Oct 25 '26

Take a look at ImageRenderer (SwiftUI) or UIGraphicsImageRenderer (UIKit)

2

u/Character-Koala6508 Oct 25 '26

Set ImageRenderer’s scale to the display scale too; it defaults to 1, so exports can otherwise be lower-resolution than a normal screenshot.

5

u/WitchesBravo Oct 25 '26

If it’s your own app you can hide the status bar using code, I don’t think there’s a way to hide it via a terminal command

3

u/Character-Koala6508 Oct 25 '26

In current SwiftUI, .toolbarVisibility(.hidden, for: .statusBar) hides it without editing the screenshot afterward.

2

u/sleekible Oct 25 '26

You can at least set the time & signal bars with simctl so the screenshots are all consistent and don’t show no signal.

4

u/MirandaU75 Oct 25 '26

Or, if you’re using a real device, plug it into a Mac and open QuickTime and connect to it, will set 9:41, full signal, full WiFi, full battery

2

u/sleekible Oct 25 '26

True. That behavior actually kind of bugs me though. I've had QA person do a screen recording that way and send it to me, and then I can't line up what's happening by time in the logs.

1

u/Character-Koala6508 Oct 25 '26

Have QA start the recording with an action that produces a log entry, so you have a clear point to sync.

1

u/icy1007 Oct 25 '26

Check the file meta data.

1

u/TheAngryKeg Oct 25 '26

The easiest way I know is to use the "Clean Up" tool inside of the Photos app when editing a screenshot.

1

u/Character-Koala6508 Oct 25 '26

If it’s their own app, hiding the bar once would save doing clean-up on every screenshot.

1

u/__markb Oct 25 '26

If using Device Hub, turn on resizability. Then you end up with same dimensions just in the rectangle.

1

u/Old-Flatworm-3032 29d ago

if it's your own app, hide it in code just for the capture run (.statusBarHidden(true) or .toolbarVisibility(.hidden, for: .statusBar)), way faster than erasing in figma every time. and if these are for store screenshots, i made a mac app that handles the framing/text/every device size part so you only redo it once: studio.hearhere.media

1

u/Background_Pie_5682 29d ago

You can override the Simulator status bar so clock/battery don’t show up in captures:

xcrun simctl status_bar booted override --time "9:41" --batteryState charged --batteryLevel 100 --cellularMode active

For a cleaner App Store look, some people also use a blank status bar setup or capture from a device with AssistiveTouch off and crop in Figma only if needed. The simctl override usually saves the manual erase step.

1

u/Significant-Young586 28d ago

Try xcrun simctl status_bar booted override --time "9:41" --batteryLevel 100 --batteryState charged. The bar stays, but every screenshot looks the same and clean.

0

u/CyberYevhen 29d ago

simctl can’t remove the status bar completely, but it can make it clean and identical across screenshots, which is usually what you want. This is the same 9:41 look Apple uses in its own marketing:

xcrun simctl status_bar booted override --time 9:41 --dataNetwork wifi --wifiMode active --wifiBars 3 --cellularMode active --cellularBars 4 --batteryState charged --batteryLevel 100

It stays until you run xcrun simctl status_bar booted clear or reboot the simulator. Then xcrun simctl io booted screenshot shot.png gives you a full-resolution PNG, no Figma cleanup needed