[EN] | RU
Example of using Supabase with Flutter
This example application demonstrates the integration of supabase.com with a Flutter app for the Aurora OS and shows how to perform common database and authentication operations.
Table of Contents
- Installation and Setup
- Screenshots
- Compatibility
- Use Cases
- Project Structure
- Known Issues
- Terms of Use and Participation in Development
Installation and Setup
Supabase Setup
Creating a Supabase Project
To begin, create a project at supabase.com.
Configuring Supabase Credentials
In lib/main.dart, initialize the Supabase SDK using your project’s URL and anonymous key:
await Supabase.initialize(
url: 'YOUR_SUPABASE_URL', // Replace with your project's URL
anonKey: 'YOUR_SUPABASE_ANON_KEY' // Replace with your project's public anonymous key
);
Explanation:
-
SUPABASE_URL: The unique URL of your project, available in the Supabase dashboard. -
SUPABASE_ANON_KEY: Public "anonymous" API key for client-side access.
Security tip: In production, avoid storing keys directly in code. Use environment variables instead (e.g., via flutter_dotenv).
Creating a Table in Supabase
In the Supabase dashboard, create a table named profiles with the following columns:
-
id:uuid -
username:text -
website:text
Aurora OS Setup
Declaring Permissions in the .desktop File
Supabase requires internet access. The .desktop file at
aurora/desktop/ru.aurora.supabase_aurora_example.desktop must include:
[X-Application]
Permissions=Internet
Screenshots
![]() |
![]() |
Compatibility
- Flutter: Version 3.32.7 and above
- Supabase: Compatible with current Supabase features
- Aurora OS: Tested with Aurora OS 5.0.0 and newer
Use Cases
User Authentication
- Sign up: Enter email and password and press "Signup"
- Login: Enter existing credentials and press "Login"
- Sign out: Press "Sign Out" on the profile screen
Profile Management
- View profile: Displays the current user’s username and website (if available)
- Update profile: Modify username and/or website and press "Save" to update in Supabase
Project Structure
The project follows a standard Flutter layout with Aurora OS support:
-
lib/main.dart: Main logic, UI widgets for login/signup/profile, Supabase integration -
aurora/: Contains Aurora OS–specific files -
pubspec.yaml: Project dependencies includingsupabase_flutterand Aurora-specific overrides (e.g.,shared_preferences_aurora)
Known Issues
During build, a MissingPluginException may occur, related to the listen method on com.llfbandit.app_links/events.
This happens due to the lack of app_links plugin support on Aurora OS.
Note: This issue does not affect Supabase functionality. It can be safely ignored if the app works as expected.
Terms of Use and Participation in Development
The source code of the project is provided under license, which allows to use it in third-party applications.
To participate in the development of the project, please read the member agreement. If you plan to submit your own source code for inclusion in the project, you will need to accept the CLA terms and conditions.
Participant information is listed in the AUTHORS file.
The Code of Conduct is the current set of rules of the Open Mobile Platform Company, which informs about the expectations for interaction between community members when communicating and working on projects.

