# How to Get Gemini API Key (Step by Step Guide) | 2026
Author: Ayush Chaturvedi
Author URL: https://elephas.app/blog/author/ayush-chaturvedi
Published: 2024-06-27
Meta Title: How to Get Gemini API Key (Step by Step Guide) | 2026
Meta Description: Learn how to get Gemini API key and use it for your projects in 2026
Tags: Writing tools, AI assistant
Tag URLs: Writing tools (https://elephas.app/blog/tag/writing-tools), AI assistant (https://elephas.app/blog/tag/ai-assistant)
URL: https://elephas.app/blog/how-to-get-gemini-api-key-step-by-step-guide-or-2024-clxx2vrh50021hnqbsyccrm7u

Gemini is one of the most powerful LLM Models available for free.  This AI model can write text and code for you. To use Gemini, you need a special key called an API key. You can get this key for free by following a few steps. There are different plans for using Gemini, some free and some that you have to pay for.

The free plans limit how much you can use Gemini, but the paid plans don't have any limits. There are also some things to keep in mind when using Gemini, like the fact that it works well only with English for now and many more. We will discuss all those and also how to easily get your Gemini API key in simple steps. So let's get started.

## Account Creation

The Google Gemini API key unlocks access to their powerful generative AI model. It acts like a secret handshake, letting your code interact with Gemini's text and code generation features. You'll need one to experiment with Gemini through Google AI Studio or integrate it into your projects.

**Here's how to create a Gemini API Key:**

**Step 1**: Search on Google “ Google AI for Developers “

**Step 2:** You get a list of search results related to Gemini and Google. In those, select "Get Started with the Gemini API" or follow this [link](https://ai.google.dev/gemini-api).

![How to get Gemini API Key ](https://prod.superblogcdn.com/site_cuid_cl495vqej08071jpawt8inf39/images/image-cp-1719481523088-compressed.png)

**Step 3:** After you reach the above homepage screen, click on the "Get API key in Google Ai Studio" option, and you will directly access the dashboard of the Ai Studio.

![How to get Gemini API Key ](https://prod.superblogcdn.com/site_cuid_cl495vqej08071jpawt8inf39/images/image-cp-1719481524573-compressed.png)

**Step 4:** Next, you will see the above screen, and in there, select "Get API Key" to create the Google API key directly.

![How to get Gemini API Key ](https://prod.superblogcdn.com/site_cuid_cl495vqej08071jpawt8inf39/images/image-cp-1719481526059-compressed.png)

**Step 5:** That’s it now you can create different API keys according to your Gemini Plan.

## Cost

The cost of the Gemini changes according to the Gemini models you use. If you use the Gemini 1.0 Pro, there will be one cost, and [if you use the Gemini 1.5 Pro](https://elephas.app/blog/gemini-vs-chatgpt), you get one cost.

However, for free plans of the Gemini, no matter the model you use, your chat information is used to train the Gemini models. So if you have privacy concerns, we recommend choosing either a paid plan or not sharing any personal information in the Gemini.

**Gemini 1.0 Pro**

**Plan**

**Free of Charge Plan**

**Pay-as-you-go plan**

Requests Per Minute

15 RPM

360 RPM

Tokens Per Day

32,000 TPM

120,000 TPM

Requests Per Day

1,500 RPD

30,000 RPD

Input Price

Free

$0.50/1 Million Tokens

Output Price

Free

$1.50/1 Million Tokens

Data Used to Improve Gemini

Yes

No

**Gemini 1.5 Pro**

**Plan**

**Free of Charge Plan**

**Pay-as-you-go plan**

Requests Per Minute

2 RPM

360 RPM

Tokens Per Day

32,000 TPM

2 Million TPM

Requests Per Day

50 RPD

10,000 RPD

Input Price

Free

$3.50 / 1 million tokens (for prompts up to 128K tokens)

Output Price

Free

$7.00 / 1 million tokens (for prompts longer than 128K)

Data Used to Improve Gemini

Yes

No

**Gemini 1.5 Flash**

**Plan**

**Free of Charge Plan**

**Pay-as-you-go plan**

Requests Per Minute

15 RPM

1000 RPM

Tokens Per Day

1 Million TPM

2 Million TPM

Requests Per Day

1,500 RPD

Nil

Input Price

Free

$0.35 / 1 million tokens (for prompts up to 128K tokens)

Output Price

Free

$0.70 / 1 million tokens (for prompts longer than 128K)

Data Used to Improve Gemini

Yes

No

Check out [Elephas](https://elephas.app/). Elephas is an [AI writing assistant for Mac](https://elephas.app/blog/best-ai-writing-assistants) that lets you use powerful AI tools like Gemini and Claude. It helps you [write better, brainstorm ideas](https://elephas.app/blog/how-can-you-use-elephas-for-brainstorming-and-content-generation-clw6dyfvx0000q6w1wkbqgydu), and [even translate languages](https://elephas.app/blog/best-ai-research-assistants). Elephas can save you 3 hours of work each day by [automating tasks](https://elephas.app/blog/23-best-artificial-intelligence-ai-and-chatgpt-apps-in-2023-clmogobgn984043un4417w3ne8) and making your [workflow faster and easier.](https://elephas.app/blog/how-elephas-works) With Elephas, you can use major AI model APIs such as Calude, Grok, Gemini, ChatGPT, etc. Alternatively, you can also use local LLM models to safeguard your information.

It is the most productive tool for the Mac, and you can [download right now for free](https://elephas.app/pricing)(with some limitations).

## Common Errors in Gemini API

There are some common errors that you might face while using the Gemini API. Here are some of the error codes that you might see while using the Gemini API, along with a quick fix and an explanation of the error.

**Code**

**Description**

**Reason**

**Fix**

400

Bad Request Body

Malformed request

Check API references for format, examples, and supported versions. Don't use features from newer versions with older API endpoints.

403

Permission Denied

API key missing or lacks permission

Verify your API key is set up correctly and has the necessary access.

404

Not Found

Requested resource not found

Double-check that all request parameters are valid for your current API version.

429

Rate Limit Exceeded

Too many requests in a short time

Stay within the model's rate limit. If needed, request a quota increase.

500

Internal Server Error

Unexpected error on Google's side

Wait a bit and try again. If it persists, report it using the Send Feedback button in Google AI Studio.

503

Service Unavailable

Service overloaded or down

Wait a bit and try again. If it persists, report it using the Send Feedback button in Google AI Studio.

### Other Issues to Keep In Mind

**Mobile and AI Studio:** The AI Studio website isn't optimised for mobile devices yet.

**Language Support:** The API only works with English prompts. Using other languages might cause issues.


---
This blog is powered by Superblog. Visit https://superblog.ai to know more.
---

