Original Idea
Screen Time Accountability Partner A mobile app that pairs you with a friend or stranger with similar digital wellness goals, sharing weekly screen time reports and celebrating wins together.
Product Requirements Document (PRD): FocusFriend
1. Executive Summary
FocusFriend is a cross-platform mobile application designed to combat digital addiction through social accountability. By leveraging psychological principles of "body doubling" and external motivation, FocusFriend pairs users with similar digital wellness goals to share screen time metrics in real-time. The app provides a secure, privacy-first environment where users can monitor their partner's progress, send motivational "nudges," and conduct weekly reflections, ultimately fostering healthier relationships with their devices.
2. Problem Statement
Independently reducing screen time is difficult due to the lack of immediate consequences and external motivation. Existing "Digital Wellbeing" tools are solitary experiences that users easily ignore or bypass. FocusFriend addresses the "accountability gap" by introducing a social layer where a user's digital habits are visible to a trusted partner, making it harder to ignore relapses and more rewarding to achieve goals.
3. Goals & Success Metrics
- Goal 1: Reduce average daily social media usage among active users.
- Metric: 20% average reduction in "Social" category screen time after 30 days of pairing.
- Goal 2: Build long-term digital wellness habits.
- Metric: 60% of pairs maintained for at least 4 consecutive weeks.
- Goal 3: Create a high-engagement, low-friction accountability loop.
- Metric: Average of 3 "Nudges" sent per user per day.
- Goal 4: Ensure user privacy while maintaining transparency.
- Metric: <1% of users citing "privacy concerns" as a reason for account deletion.
4. User Personas
A. The "Distracted Professional" (Alex, 29)
- Role: Remote Software Engineer.
- Pain Point: Spends 3+ hours on Reddit/Twitter during work hours.
- Motivation: Needs to hit project deadlines without "hard-locking" apps entirely, just needs someone to "watch over their shoulder."
B. The "Exam-Prep Student" (Maya, 20)
- Role: University Student.
- Pain Point: Phone addiction leads to late-night scrolling and poor sleep.
- Motivation: Wants to find a stranger with similar high-intensity study goals (8 hours of focus/day).
C. The "ADHD Body-Doubler" (Sam, 34)
- Role: Freelance Writer.
- Pain Point: Executive dysfunction makes it hard to start tasks.
- Motivation: Benefits from the "presence" of another person working; uses the "Mirror View" to stay grounded.
5. User Stories
- As a user, I want to sync my screen time automatically so that I don't have to manually log usage.
- As a user, I want to hide specific apps (like my banking app) from my partner so that my sensitive data remains private.
- As a user, I want to be matched with someone in my timezone so that our active hours align for real-time nudges.
- As a partner, I want to receive a notification when my buddy is nearing their daily limit so that I can send a supportive message.
- As a user, I want to see a shared dashboard of our progress so that we can celebrate our wins together.
6. Functional Requirements
6.1 Onboarding & Permissions
- FR-1: System must request OS-level permissions for Apple Screen Time (ManagedSettings) and Android Usage Access.
- FR-2: Users must complete a "Wellness Profile" defining goals (e.g., "Reduce TikTok by 50%").
6.2 Smart Buddy Matching
- FR-3: Algorithm must pair users based on Semantic Similarity of goals and Timezone Overlap (min. 4 hours).
- FR-4: Users must be able to "Accept" or "Decline" a potential match within 24 hours.
6.3 Shared Accountability Dashboard
- FR-5: Real-time synchronization of category-level usage data (updated every 15-30 mins).
- FR-6: "Mirror View" displaying partner's current progress vs. daily limit.
6.4 Nudge & Communication System
- FR-7: Pre-set "Nudges" (Quick-actions) triggerable via WebSocket.
- FR-8: End-to-End Encrypted (E2EE) chat for discussing weekly trends.
6.5 Privacy & Data Masking
- FR-9: Default behavior must aggregate data into categories (e.g., "Entertainment" vs "Netflix").
- FR-10: Users must be able to "Blacklist" specific apps from any reporting.
7. Technical Requirements
7.1 Tech Stack (2026 Standards)
- Frontend: React Native 0.83.1 (New Architecture enabled).
- Backend: Node.js 24.13.0 (LTS) using TypeScript 6.0.
- Database: PostgreSQL with Prisma ORM 7.2.x.
- Authentication: Clerk (leveraging "Organizations" API for pair/group logic).
- Real-time: WebSockets hosted on AWS ECS (Fargate) with Redis Pub/Sub for scaling.
- Local Storage: MMKV for high-performance usage caching.
7.2 Framework-Specific Integrations
- iOS: Apple DeviceActivity and ManagedSettings frameworks (iOS 26+).
- Android: UsageStatsManager and Play Age Signals API for age-appropriate filtering.
8. Data Model
User
id: UUIDclerkId: String (External Auth)timezone: Stringgoals: JSONB (Category limits)privacy_config: JSONB (Blacklisted apps)
AccountabilityPair
id: UUIDuser_a_id: UUIDuser_b_id: UUIDstatus: Enum (Pending, Active, Terminated)e2ee_public_key_a/b: Text
UsageLog
id: UUIDuser_id: UUIDtimestamp: DateTimecategory_name: Stringduration_minutes: Integer
9. API Specification
Authentication (via Clerk)
POST /api/webhooks/user-created: Synchronize Clerk user with local DB.
Matching
POST /api/match/request: Submit profile for matching.GET /api/match/status: Polling or WebSocket event for match found.
Data Sync
POST /api/sync/usage: Upload batch category deltas from device.GET /api/dashboard/mirror: Fetch partner’s latest aggregated state.
Real-time (WebSocket)
WS /nudge: Payload{ "targetId": "uuid", "type": "warning|praise" }.
10. UI/UX Requirements
- Component: The Mirror Dial: A circular progress bar showing the user's progress in the inner ring and their partner's in the outer ring.
- Component: The Nudge Tray: A swipe-up gesture from the dashboard to send quick haptic-feedback emojis to the buddy.
- Component: Privacy Shield: An "incognito" toggle that pauses data sharing for 30 minutes (notified to the partner to ensure accountability).
11. Non-Functional Requirements
- Performance: App must not exceed 2% battery drain per 24 hours. Usage of
expo-background-taskfor deferred syncing. - Security: E2EE using The Signal Protocol for all peer-to-peer messaging.
- Availability: 99.9% uptime for WebSocket server to ensure nudges are "real-time."
12. Out of Scope
- Content filtering/blocking (focus is on accountability, not strict parental control).
- Social media feed integration (e.g., posting wins to Instagram).
- Desktop application (v1 is mobile-only).
13. Risks & Mitigations
- Risk: OS-level API changes (Apple/Google).
- Mitigation: Use cross-platform abstractions and maintain a buffer for rapid native updates.
- Risk: Harassment between strangers.
- Mitigation: Robust "Report & Block" system; Clerk-managed identity verification.
- Risk: User "cheating" (e.g., leaving the phone on a table).
- Mitigation: AI-driven wellness coach identifies unusual static usage patterns.
14. Implementation Tasks
Phase 1: Project Setup
- [ ] Initialize project with React Native 0.83.1 using the New Architecture.
- [ ] Set up Node.js 24.13.0 backend with Prisma 7.2.x.
- [ ] Configure Clerk Auth for mobile (Native SDK).
- [ ] Initialize AWS ECS cluster for WebSocket testing.
Phase 2: OS Integration & Local Tracking
- [ ] Implement ManagedSettings bridge for iOS.
- [ ] Implement UsageStatsManager module for Android.
- [ ] Build local MMKV storage logic for category-level aggregation.
- [ ] Create privacy-masking logic to filter out blacklisted package names.
Phase 3: Matching & Social Core
- [ ] Build Gale-Shapley based matching algorithm in the backend.
- [ ] Implement Pair/Circle logic using Clerk Organizations.
- [ ] Develop Signal Protocol E2EE integration for buddy-chat.
- [ ] Build "Find a Buddy" onboarding flow.
Phase 4: Shared Dashboard & Real-time
- [ ] Implement Redis Pub/Sub on ECS for cross-node nudge delivery.
- [ ] Build the "Mirror Dial" UI using React Native Skia.
- [ ] Create Worklet-based animations for progress bar interpolation.
- [ ] Implement weekly reflection "Review Room" UI.
Phase 5: Optimization & Launch
- [ ] Audit battery impact using Xcode Energy Impact and Battery Historian.
- [ ] Configure Expo Background Task for battery-efficient syncing.
- [ ] Perform penetration testing on E2EE implementation.
- [ ] Deploy to App Store and Google Play.