Aider is safe to use, but its workflow adds one specific risk: it commits changes to git automatically by default. That means if it inlines a secret to make code run, the secret can be in your history before you have looked at the change. The underlying weaknesses are the usual ones for a capable assistant, hardcoded credentials and missing authorization, made easier to miss by the auto-commit step.
The risks that actually matter
Secrets committed automatically
Aider's default is to commit each change. A key it inlines can enter git history immediately, and removing a secret from history is harder than preventing it.
Hardcoded credentials
As with any assistant, when an integration needs a key Aider may write the literal value so the code runs, rather than reading it from the environment.
Missing server-side authorization
Generated endpoints can skip the auth check that is not required for the feature to function, leaving them callable by anyone.
How to secure a Aider app
- Add a pre-commit secret scanner (such as gitleaks) so an inlined key fails the commit.
- Keep .env and .env.local gitignored before you start a session.
- Review each auto-commit, and prompt Aider to use environment variables for all secrets.
- Add server-side auth to any route it generates, and scan before you push.