What is App Data?
App Data lets your apps do more than just display information. With App Data enabled, your apps can:- Save your data - Store and retrieve information that persists between sessions
- Upload files - Let users upload images, videos, PDFs, and more
- User accounts - Allow users to sign up, log in, and have their own private data
- Real-time updates - Data syncs instantly across all users
App Data is powered by Supabase, an open-source cloud platform.
Getting Started
Step 1: Create a Supabase Account
- Go to supabase.com
- Sign in or create a free account
- Click New Project
- Fill in your project details:
- Project name (e.g., “My App”)
- Database password (save this somewhere safe)
- Region (choose the one closest to your users)
Step 2: Get Your Keys
Once your project is created:- Go to Project Settings (⚙️ icon in sidebar)
- Click on API
- Copy these two values:
- Project URL:
https://xxxxx.supabase.co - Anon Key: A long string starting with
eyJ...
- Project URL:
Step 3: Connect to CodeRocket
- Go to Account → Integrations in CodeRocket
- Click Add Integration on App Data
- Paste your Project URL and Anon Key
- Click Test Connection to make sure it works
- Click Save
What Gets Generated
When you enable App Data for a project and ask for features that need to save data, CodeRocket automatically creates:1. Connection Code
src/lib/supabase.ts
2. TypeScript Types
src/types/database.types.ts
3. Data Hooks (for React projects)
Code to load and save data from your components:src/hooks/usePosts.ts
Example Prompts
Here are some things you can ask CodeRocket to build:Save Data
User Accounts
File Uploads
Running SQL Migrations
When CodeRocket generates features that need to save data, it creates SQL code that you need to run in Supabase:- Copy the SQL code from CodeRocket
- Go to your Supabase Dashboard
- Click SQL Editor in the sidebar
- Paste the SQL code
- Click Run
Real-time Updates
Want data to sync instantly across all users? Just ask:File Uploads
Your apps can let users upload images, videos, documents, and more. Just describe what you need:Supported File Types
- Images: PNG, JPEG, GIF, WebP
- Videos: MP4, WebM
- Documents: PDF, TXT, and more
How It Works
CodeRocket generates everything you need:- SQL migration - Creates a storage bucket in Supabase
- Upload code - Handles the file upload process
- UI component - File picker with upload progress
Files are stored securely in the cloud and delivered fast via CDN. Default limit is 50MB per file.
Tips
Test with a free project first
Test with a free project first
Create a free Supabase project for testing. Once everything works, you can switch to your production project.
Your data is secure
Your data is secure
CodeRocket automatically generates security rules (RLS policies) that protect your data. Users can only access their own data by default.
No extra configuration needed
No extra configuration needed
CodeRocket automatically injects your Supabase credentials. You don’t need to set up environment variables manually.
Troubleshooting
”Failed to connect”
1
Check your Project URL
Make sure it looks like:
https://xxxxx.supabase.co2
Check your Anon Key
Copy it fresh from Supabase dashboard → Settings → API
3
Make sure your project is running
Free Supabase projects pause after 1 week of inactivity. Go to your dashboard and restart if needed.
”Data not showing up”
- Make sure you ran the SQL migration in Supabase
- Check if you’re logged in (if the app requires it)
- Try refreshing the page
For Developers
Technical Details (Click to expand)
Technical Details (Click to expand)
App Data is powered by Supabase, which provides:
- PostgreSQL Database - Powerful relational database
- Row Level Security - Data access rules at the database level
- Real-time Subscriptions - Live data sync via WebSockets
- Storage - S3-compatible file storage with CDN
- Edge Functions - Serverless functions (Deno)
@supabase/supabase-js client library.For advanced use cases like custom RLS policies, database functions, or edge functions, you can access your Supabase dashboard directly.
