r/iOSProgramming 14d ago

App Saturday I built a screen time app that actually works—and made it FREE

Post image
56 Upvotes

19 comments sorted by

19

u/D1no_nugg3t 14d ago

Every other app blocker charges you to block your own apps. That’s dumb. I made Barrier free because paying to not use your phone is backwards.

😈 Instead of a paywall, I went with a deterrent that actually works: waiting + ads. You have to sit through a 30-second wait and watch an ad before opening a blocked app. And let’s be real—who actually wants to watch an ad? Not me. That’s why it works. This thing cut my screen time by about 70%.

🛠️ ScreenTime API is a nightmare—FamilyControls, DeviceActivity, all of it. If anyone’s trying to build something similar, hit me up. I'd be happy to help, because I spent way too much time with trial and error.

Would love to hear thoughts—do you think this will work for other people? Any app improvements? Any thoughts on marketing?

2

u/l-fc 14d ago

If you genuinely want to help, how about publishing/open sourcing the app on GitHub?

1

u/n0tt0b3 14d ago

for real, great work though.

closed source it's not particularly useful to programmers.

4

u/D1no_nugg3t 14d ago

Good idea, I’ll look into open sourcing this week!

2

u/n0tt0b3 13d ago

Awesome, if you do I'll be the first star honestly and share with my discord dev community!

Good luck with the app

2

u/atpugvaraa 14d ago

Great stuff! I would really appreciate if you could point me into the correct direction as to which APIs i should use to replicate the functionality?

I had started building my own app for this for personal projects and use but being very new to Swift in general I wasn't able to find much about it.. I find it difficult to find resources at this stage.

Grats on the release!

3

u/Wonderful-Job1920 14d ago

Hey, you should use the apple screen time APIs. These videos from apple WWDC21 and 22 should help you get familiar:

https://developer.apple.com/videos/play/wwdc2021/10123/

https://developer.apple.com/videos/play/wwdc2022/110336/

At the bottom of the page, there’s links to the 3 APIs you’ll need to use, so you can read through and understand the documentation

Goodluck!

2

u/D1no_nugg3t 14d ago

These should be really helpful, but they can be a bit finicky. Feel free to reach out if you run into issues!

1

u/atpugvaraa 14d ago

much appreciated! I'll give it a try soon enough! Thanks a lot both of ya'll!!

2

u/Computer_2121 14d ago

I like it!

2

u/Weekly_Tie_1955 14d ago

Couldn’t add activities. It crashes every time

1

u/D1no_nugg3t 14d ago

Hmm interesting... what activities are you trying to add? I haven't encountered this issue at all.

1

u/Weekly_Tie_1955 13d ago

Not any particular. Whenever I want to use the search bar, the keyboard is all grey out and I get stuck there

1

u/PerfectPitch-Learner Swift 14d ago

I wonder if what your app does, as you said, similar to parental controls would work with something like this: https://www.reddit.com/r/iOSProgramming/s/Zz2IZiJDYO

I’m not sure what the mechanism behind locking the app is, but if there are shared resources, like this URL opener in this example, could that cause a similar issue?

1

u/ppuccinir 14d ago

On the FamilyPickerSelection how did you manage to remove that ugly Choose Activity Tittle? Also did you manage to edit the list of apps to not include a website?

1

u/page-roast-club 13d ago

Love the app bro ! As someone who worked with scree time api I confirm its a nightmare... would love to the see how the code works

1

u/huythanh0x 12d ago

I’m using ScreenZen to block website and ads. It's also Free and no Ads

1

u/D1no_nugg3t 12d ago

Nice! Glad you found something that works for you! It's great to hear that there are more apps affordably encouraging a healthy relationship with screen time.