How To Generate API key for Google Gemini and Open AI

Screens change from time to time, so button names may look slightly different, but the flow stays the same.

Part 1: Google Gemini API key

  1. Open https://aistudio.google.com/apikey in your browser.
  2. Sign in with your Google (Gmail) account.
  3. Accept the Terms of Service if it asks.
  4. Click Create API key.
  5. If asked, choose a project (or let it create a new one for you).
  6. Your key appears on screen. Click the copy icon and paste it somewhere safe, like a password manager.

Gemini has a free tier with limits. For heavier use, you may need to enable billing in the linked Google Cloud project.









Part 2: OpenAI API key

  1. Open https://platform.openai.com (this is different from chatgpt.com).
  2. Click Log in, or Sign up if you don’t have an account. You can use email, Google, or Microsoft.
  3. Verify your email and phone number if asked.
  4. Add billing: go to Settings → Billing and add a payment method with some credit. OpenAI keys usually won’t work without credit.
  5. Go to https://platform.openai.com/api-keys.
  6. Click Create new secret key, give it a name (e.g., “My Provider”), and click Create.
  7. Copy the key immediately. OpenAI shows it only once. If you lose it, you’ll need to create a new one.