“An internal error occurred” Appears on Every Prompt

I’m having a persistent problem in Google AI Studio when building my webapp. Every time I send a prompt, I get the message “An internal error occurred.” and retrying does nothing. Refreshing the page

What I’ve already tried:

  1. Clearing cache & cookies
  2. Switching browsers
  3. Signing out/in
  4. Using a different device
  5. Using a VPN
  6. Starting a new chat
  7. Rebuilding a new app (this works until I import old files)

then the same error starts again. When I restore a previous version of the project, prompts work at first, but as soon as I send a new one, the error returns. please help me.

2 Likes

O meu ocorre ttambém então esses procedimentos não funcionam sempre, deve ser ser coisa do servidor do Google.

Hi @Djilali_Behourah @Rene_Augusto_Negrao ,

This issue appears to be caused by a specific file in your project or by exceeding AI Studio’s input-context limits. To resolve it, try importing your files in smaller batches to identify the one triggering the error. Once found, you can remove, reorganize, or regenerate that file to ensure compatibility. If the problem continues, reduce the input context, temporarily switch to a another model(e.g. from Gemini 2.5 Pro to Gemini 3 Pro), or wait briefly before retrying.

Thanks.

Hey,

Hope you’re keeping well.

This usually points to an issue with the project configuration or files being imported rather than a browser or device problem. In AI Studio, errors like this can occur if the prompt or app logic is referencing missing assets, malformed JSON, or an unsupported model parameter. Try creating a new project and importing files incrementally to identify which specific file or change triggers the error. Once you isolate it, check the Prompt settings and Model configuration in AI Studio, and review the browser DevTools network tab for failed API calls. If the error persists with a minimal project, capture the request/response details and file a bug via Google AI Studio support so the team can investigate server-side logs.

Thanks and regards,
Taz

Limite de contexto? Mesmo sendo só um: “Vamos continuar o trabalho! “ Eu imagino que o limete deva ser grande mas mesmo assim não usaria esse limete. Então meu prompt não tem muitos dados.

Obs. Quando minha conversa com o chat está chegando a um pouco mais de 200 ou 300 mil tokens já estou mudando para nova janela

1 Like

No, that’s not it, at least on my side. I am getting the same error even without uploading any images and using short prompts.

1 Like

@Rene_Augusto_Negrao @dhnation

Are you both still experiencing this issue? Also, which Gemini model are you currently using?
Thanks

On my end it seems to be fixed, thank you. I am facing another issue (different topic but also Gemini 3 Pro Image Preview related) though, but unfortunately nobody seem to have an answer for that either.

No inicio usava o Gemini 2.5 Pro depois sai dele e tentei usar outro é mais rapido porém tem outro recurso que o 2.5 pro é mais para eu gerar conteúdo de apostilas mais detalhado não importa a velocidade. Porém começou a gerar erros entao comecei a pesquisar no propria AI Studio formas de contornar a situação, gerar system instruction guardar no bloco de notas, resumir o conteúdo da jenela já com 200 ou 300 mil tokens e fezer outra janela e jogar tudo lá dentro.
No momento estou usando o Gemini 2.5 flash.