You can create a Gemini API key in Google AI Studio without paying for the key itself. Free API usage is limited to eligible models and quotas; paid features and usage are separate.
Steps to create a free API key for Gemini AI
1. Open Google AI Studio
Go to Google AI Studio’s API Keys page and sign in with your Google account. New users get a default project and key after accepting the terms; existing Google Cloud users may need to import a project first, as described in step 3.
2. Create API Key
If you need a new key, click Create API key on the API Keys page. New keys created in AI Studio are authorization keys, bound to a service account and restricted to the Gemini API by default. If key creation is unavailable, ask your project administrator to check your permissions.
3. Choose or Create a Project
Use your default project or an existing project you are authorized to manage. If your project is missing, open Dashboard → Projects → Import projects, select it and click Import. Return to API Keys to create the key in that project. You do not need a new project for each key.
4. Copy Your API Key
Copy the key from the API Keys page and store it in a server-side environment variable or secret manager. Use it in your backend application or trusted tool configuration, not in public browser code.
Additional tips
Key tips for using your Gemini API key safely
- Keep it secret: Never publish the key in Git or embed it in production web or mobile apps. Make API calls through your backend.
- Replace exposed keys: Create a replacement, update and verify your application, then disable or delete the compromised key. Check usage and billing for unexpected activity.
- Existing keys: Google is moving from standard keys to authorization keys. Follow the current migration guidance in the official key documentation below.
- Usage & limits: A free key does not provide unlimited free requests. Check model pricing, quotas and regional availability before enabling billing or sending requests.
Official guidance checked 10 September 2026: https://ai.google.dev/gemini-api/docs/api-key and https://ai.google.dev/gemini-api/docs/pricing.
Prefer to use Gemini in Google Sheets without managing API keys? Try our add-on: AI for Sheets.