Securing your Flutter API Keys (Environment variables)

Delivered a talk
Conduct a code section
At some point, every flutter developer will need to use environment variables in a Flutter project, this is a guide on how to do it in a secure way.

Some packages handle the environment variables only during a process, which takes time to load and will load every time you open the app. Also some export the .env file into the assets and load the file during the app runtime, this also has its downside because we can't access them as constant expressions and most especially the asset directory can be accessed directly by unzipping the APK, thus .env file is not secure, and anyone can access it.

This session will show developers how to use environment variables securely, how to use them as constant expressions, and how to obfuscate them.

It will be a live coding session.