Skip to main content
Hostwares

How to Test a Supabase Migration Before Switching Production

sowad sheikh··1 min read

Testing a Supabase Migration Before Production

A successful database restore is only the beginning. Your application depends on many backend components, so test the entire system before changing production.

1. Check Database Structure

Compare important tables, columns, indexes, functions, and extensions.

2. Verify Data

Check row counts and sample records. For important tables, compare the source and destination.

3. Test Authentication

Test: Login Registration Logout Password reset OAuth if used Protected routes

4. Test Storage

Upload and download files. Verify private files remain private.

5. Test API Requests

Run the application's most important API operations.

6. Test RLS

Security policies should behave exactly as expected. Try both authorized and unauthorized operations.

7. Test Realtime

If your application uses live updates, verify subscriptions and database events.

8. Test the Real Application

Finally, connect a staging build to the new environment.

If everything works, plan the production cutover. A migration is complete only when the application—not just the database—works correctly.

Ready to deploy?

Launch your app on Hostwares — start for $1.00/mo with auto-scaling & global CDN.

Start for $1.00/mo

Ready to deploy? Start for $1.00/mo

Deploy now