(This is all that the message said for me. I noticed others encountering this error usually had more info attached to their error messages, like this one)
I do have billing set up & enabled for my project, and Google Cloud says:
You’ve activated your full account
0 out of $417 credits used
However, inside Google AI Studio, my API key’s Quota tier is shown as “Unavailable”, and I always get the error “You are out of free generations. You can continue by using your own paid API key.”
This does not happen if I unlinked my API key. While my API key is linked, I have yet to send out a single successful request.
When I open the Rate Limit dashboard, I get the following message, despite being the project’s admin:
Project quota tier unavailable. Please contact your project administrator for assistance.
Would appreciate anyone with relevant info on how to resolve this.
It sounds like your API key is not yet mapped to an active quota tier in the Gemini API backend, even though billing is enabled. This can happen if the key was created in AI Studio but the linked Google Cloud project does not have the Generative Language API (or the specific Gemini API) enabled, or if there’s a mismatch between the project in Cloud Console and the one AI Studio is showing.
In Cloud Console, go to APIs & Services > Library and ensure the relevant Gemini API is enabled for the same project your key belongs to. Then check IAM & Admin > Quotas to confirm you can see rate limits for that API — if it still says “unavail
The fix is that instead of creating a new api from the Google AI Studio, first create a new project from the console & enable Gemini API, and then import the new project into the API Studio & create a new API.
I believe the problem currently is that, AI studio is not able to sync back once the billing is mapped in the console.
We appreciate you bringing this to our attention. If you have a moment, could you please try the troubleshooting steps already suggested in this community thread?
Let us know if the issue persists after trying those steps—we’re happy to look into this further for you.
I spent 6 hours running in circles and this not only worked but also fixed the other projects with the same issue. As soon as I did this, I could see Tier 1 under Quota Tier at https://aistudio.google.com/api-keys. It was all Unavailable before.
I am absolutely MAD that a company so big like Google can let something like this happen. I lost a day of my life talking to chatgpt and gemini giving me wrong advice and reading endless documentation page, just to find out that the fix was literally a “hack”.
+1 for this fix working. For others who may not know where to make new projects (this took me about 20 minutes to figure out) - upper left hand to the right of “Google Cloud” you click that and it will open a project picker which will have a link to create a new project.
Didn’t work for me the method of creating the Project from Google Console and Enabling Gemini API Service aka Generative Language API to then import it into Google AI Studio.
I’m in Free Tier and haven’t used the API keys, it’s the first request with the new key.
——— Project details
Name: MacroLogTest
———
I have even created another Gmail account but it didn’t work either.
———-
Shell Input and Output
curl "https://generativelanguage.googleapis.com/v1beta/models/gemini-2.0-flash:generateContent" \
-H 'Content-Type: application/json' \
-H 'X-goog-api-key: [CENSORED_API_KEY]' \
-X POST \
-d '{
"contents": [
{
"parts": [
{
"text": "Explain how AI works in a few words"
}
]
}
]
}'
{
"error": {
"code": 429,
"message": "You exceeded your current quota, please check your plan and billing details. For more information on this error, head to: https://ai.google.dev/gemini-api/docs/rate-limits. To monitor your current usage, head to: https://ai.dev/rate-limit. \n* Quota exceeded for metric: generativelanguage.googleapis.com/generate_content_free_tier_requests, limit: 0, model: gemini-2.0-flash\n* Quota exceeded for metric: generativelanguage.googleapis.com/generate_content_free_tier_requests, limit: 0, model: gemini-2.0-flash\n* Quota exceeded for metric: generativelanguage.googleapis.com/generate_content_free_tier_input_token_count, limit: 0, model: gemini-2.0-flash\nPlease retry in 27.416418769s.",
"status": "RESOURCE_EXHAUSTED",
"details": [
{
"@type": "type.googleapis.com/google.rpc.Help",
"links": [
{
"description": "Learn more about Gemini API quotas",
"url": "https://ai.google.dev/gemini-api/docs/rate-limits"
}
]
},
{
"@type": "type.googleapis.com/google.rpc.QuotaFailure",
"violations": [
{
"quotaMetric": "generativelanguage.googleapis.com/generate_content_free_tier_requests",
"quotaId": "GenerateRequestsPerDayPerProjectPerModel-FreeTier",
"quotaDimensions": {
"model": "gemini-2.0-flash",
"location": "global"
}
},
{
"quotaMetric": "generativelanguage.googleapis.com/generate_content_free_tier_requests",
"quotaId": "GenerateRequestsPerMinutePerProjectPerModel-FreeTier",
"quotaDimensions": {
"location": "global",
"model": "gemini-2.0-flash"
}
},
{
"quotaMetric": "generativelanguage.googleapis.com/generate_content_free_tier_input_token_count",
"quotaId": "GenerateContentInputTokensPerModelPerMinute-FreeTier",
"quotaDimensions": {
"location": "global",
"model": "gemini-2.0-flash"
}
}
]
},
{
"@type": "type.googleapis.com/google.rpc.RetryInfo",
"retryDelay": "27s"
}
]
}
}