A personal, intimate digital space for long-distance partners to share letters, memories, and moments—no matter the distance.
- Encrypted Content: All letter content is secured with AES End-to-End Encryption.
- Rich Media Editor: Create beautiful letters with rich text editing (TipTap), photos, videos, audio recordings, and music embeds (Spotify & SoundCloud).
- Interactive Reveals: Features an envelope-opening animation, with optional password or puzzle/riddle protection, and confetti animations on open.
- Scheduled Delivery: Letters can be scheduled to unlock at a specific date and time.
- Shared Journal: A thread-style space for daily thoughts and back-and-forth conversations with your partner.
- Memory Gallery: A shared timeline of photos, quotes, and moments, organized by date.
- Countdown Timers: Track reunions, anniversaries, and other special dates with a real-time display.
- Themes: Choose from multiple aesthetics: Minimal, Vintage Paper, Scrapbook, and Storybook.
- Frontend: Next.js 14, React, TypeScript.
- Styling/UI: Tailwind CSS, Custom CSS, Framer Motion for animations, TipTap (Rich Text Editor).
- Backend/Database: Supabase (PostgreSQL).
- Auth/Storage: Supabase Auth & Storage (for media files).
- Security: CryptoJS (AES encryption).
Follow these steps to get the application running on your local machine.
Before starting, ensure you have:
- Node.js 18+ installed.
- A Supabase account.
npmoryarnpackage manager.
# Clone the repository
git clone <your-repo-url>
cd dear-distance
# Install dependencies
npm install
# or
yarn install- Create Project: Create a new project at supabase.com.
- Run Schema: Go to the SQL Editor in your dashboard. Copy the entire contents of the local
database/schema.sqlfile and run it to set up all tables and RLS policies. - Setup Storage: In the Supabase Storage section, create a new Public bucket named
dear-distance-mediafor media uploads. - Get Keys: Retrieve your
Project URLand API keys (anon public and service_role) from Project Settings > API.
Create a file named .env.local in the root directory and fill in your keys.
# Supabase Credentials
NEXT_PUBLIC_SUPABASE_URL=[https://your-project-id.supabase.co](https://your-project-id.supabase.co)
NEXT_PUBLIC_SUPABASE_ANON_KEY=your-anon-key-here
SUPABASE_SERVICE_ROLE_KEY=your-service-role-key-here
# Encryption Key (Must be 32 bytes base64-encoded)
# Generate using: openssl rand -base64 32
ENCRYPTION_KEY=paste-your-generated-key-here
NEXT_PUBLIC_APP_URL=http://localhost:3000
NEXT_PUBLIC_EMAIL_NOTIFICATIONS_ENABLED=falsenpm run dev
# or
yarn devOpen [http://localhost:3000] in your browser to begin.
- Create Accounts: Sign up with your account and have your partner sign up with theirs.
- Connect Partner: In Settings, enter your partner's email in the "Partner Email" field. Both partners must do this to link their accounts for shared features.
| Issue | Potential Solution |
| "Partner email not found" | Ensure both users have signed up and the email is entered correctly (case-insensitive if schema fixed). |
| "Failed to decrypt content" | Verify your ENCRYPTION_KEY is set correctly and has not been changed since creating the letters. |
| "Failed to upload media" | Confirm the dear-distance-media bucket exists and is set to Public in Supabase Storage. |
| Authentication issues | Clear browser cookies and ensure Supabase API keys in .env.local are correct. |
This project is licensed under a Proprietary License.
Copyright 2025 Saachi Gupta - All Rights Reserved.
This application's source code is the confidential and proprietary information of the copyright holder. Unauthorized use, reproduction, or distribution of this source code is strictly prohibited.