← Christopher Yarbro

Social Rewind

Use social media without the parts built to keep you scrolling.

Swift · SwiftUI · TypeScript · Screen Time APIIn progressSource

Social Rewind locks the social media apps on your iPhone using Apple's Screen Time frameworks. In their place, it opens the platform's own website inside the app, with the features you chose removed: Reels, Explore, suggested posts, ads, comments. You can also pick a mode such as "DMs only" or "Saved posts only". Instagram is the first platform. It's in early development and isn't on the App Store yet.

Locking the native app

During onboarding you pick each platform's app in Apple's app picker, and Screen Time shields it. Tapping a shielded app shows a custom shield screen, and one tap on its button opens Social Rewind straight to that platform's filtered view.

A shield's buttons can only answer with a fixed set of responses. Apple documents one that opens the app that applied the shield, but the current SDK leaves it out of the Swift interface, so the extension passes its raw value. The response can't say which platform was tapped. So just before answering, the extension writes a handoff record to storage it shares with the app, and the app reads it once, within 30 seconds, when it opens. On iOS versions without that response, the shield falls back to posting a notification that deep-links into the app. Home Screen shortcuts use the same deep link.

Filtering the website

A filter engine written in TypeScript is injected into the web view before the site's own scripts run. It works in layers:

Two content worlds

The first version of the engine ran as a single script alongside the site's code. A review found that the site's scripts could read its configuration, call its API to switch filtering off, and forge messages to the native app. The engine is now split across two WebKit content worlds:

The two worlds share only the DOM, and the isolated side treats anything it reads there as untrusted. Configuration is passed into each bundle in a closure, so page scripts can't read it. Route blocking in JavaScript is best-effort. The native app watches the web view's URL and is the authority on where you're allowed to go.

Rule packs

What to hide lives in declarative JSON rule packs, one per platform, kept separate from the engine. When Instagram changes its markup, the fix usually goes in the rule pack and the engine stays the same. A pack can't carry scripts or add hosts, and its redirects can only point at paths on the same site. A JSON schema rejects unknown fields in CI. The engine and the native app read only the fields they know, and the native app checks redirect targets and size limits when it loads a pack.

Privacy

There are no servers, accounts, analytics, or tracking. Settings and stats stay on the phone. The app contacts only the sites you open in it. If you turn on rule updates (off by default), it also downloads new rule packs from the project's GitHub repository.

Next

Sign-in comes next, with help for each kind of login check Instagram throws up. After that, the app will block the platforms' websites in Safari so they can't be used to get around the lock, and rule packs will be signed before rule updates ship in a release. More platforms come later, then Android.