AI Assistant Not Responding: Common Causes and Step-by-Step Fixes
This runbook is for customers who see an AI assistant hang, return an error, or stay silent when users send a message. It walks you through the most common causes in the right order, with simple dashboard checks first and copy-paste commands second, so you can quickly find the issue and apply the right fix.
TL;DR — If the AI assistant sometimes does not answer, the most common causes are an expired API key, usage limits being hit, a broken webhook or backend timeout, or safety/routing rules dropping the request before it reaches the model. Start by checking your provider dashboard for failed requests and quota errors; if you only do one thing, confirm the API key is valid and that you still have available usage. Reading time: ~6 min
The scenario
It is a normal Tuesday afternoon. A customer opens your site chat, types a perfectly ordinary question, and the typing indicator spins for a while before nothing appears. A few conversations work, a few fail, and your team cannot tell whether the problem is the AI provider, your website, or some rule in the middle. The dashboard may still show your app as "up," which makes this extra confusing because users are clearly seeing silence instead of answers.
Symptoms
- The user sees one of these behaviors:
- The assistant shows a typing/loading state and then nothing appears.
- The assistant replies in some chats but not others.
- The send button works, but the message never gets a response.
- Common API or app errors in logs:
401 Unauthorized 403 Forbidden 429 Too Many Requests 500 Internal Server Error 502 Bad Gateway 503 Service Unavailable 504 Gateway Timeout - Common provider or backend messages:
Invalid API key Rate limit exceeded Insufficient quota context_length_exceeded upstream request timeout webhook delivery failed - Browser developer tools (the browser's built-in request inspector) may show:
Failed to fetch net::ERR_BLOCKED_BY_CLIENT CORS error - Web server or app logs may show lines like:
POST /api/chat 504 Error: socket hang up Error: ETIMEDOUT Error: request aborted
Likely causes
| Cause | How common | Quick check |
|---|---|---|
| Invalid, expired, or missing AI provider API key | Very common | In your provider dashboard, open API keys and confirm the key used by your app is active and not revoked |
| Rate limit or quota exhausted | Very common | In your provider dashboard, open Usage/Billing and look for 429 errors, zero remaining credit, or hard usage caps |
| Your backend or webhook timed out before the model replied | Common | In your app/server logs, search for 504, ETIMEDOUT, or upstream request timeout |
| A moderation, guardrail, or routing rule blocked the request | Common | In your app dashboard or logs, search the failed request for blocked, filtered, policy, or a fallback route |
| The browser request failed before it reached your backend | Sometimes | In the browser, open Developer Tools → Network and retry the message; look for a failed POST request |
| Provider outage or degraded service | Sometimes | Check your AI provider's public status page and compare the timestamp with your failures |
Step-by-step diagnosis
-
Check whether the AI provider is currently degraded.
- Menu path: open your provider's public status page in a browser.
- This is your problem if you see an active incident affecting API responses, elevated latency, or errors during the same time window.
- Jump to: Fixes → Provider outage or degraded service.
-
Check whether your API key is valid.
- Menu path: in your provider's dashboard, open the API keys page and find the key your app uses.
- CLI option if you have server access:
printenv | grep -E 'OPENAI|ANTHROPIC|AI|API_KEY'- This is your problem if the key is missing, revoked, expired, or different from the one configured in your app.
- Jump to: Fixes → Invalid, expired, or missing AI provider API key.
-
Check quota and rate limits.
- Menu path: in your provider's dashboard, open Billing, Usage, or Limits.
- This is your problem if you see
429 Too Many Requests,Insufficient quota, a hard monthly cap, or no available credit. - Jump to: Fixes → Rate limit or quota exhausted.
-
Check your own app logs for timeout errors.
- Menu path: in your hosting provider's dashboard, open your app/service → Logs.
- CLI option:
grep -Ei '504|ETIMEDOUT|timeout|socket hang up|request aborted' /var/log/* 2>/dev/null- This is your problem if the request starts but your app returns
504,502, or timeout errors before a model response arrives. - Jump to: Fixes → Your backend or webhook timed out before the model replied.
-
Check whether a rule blocked the message.
- Menu path: in your app admin area, open conversation logs, moderation logs, or workflow/routing rules.
- This is your problem if the request is marked blocked, filtered, or routed to a path with no response action.
- Jump to: Fixes → A moderation, guardrail, or routing rule blocked the request.
-
Check the browser request itself.
- Menu path: in Chrome/Edge/Firefox, press
F12→ Network → send a test message → click the failedPOSTrequest. - This is your problem if the request never leaves the browser, shows
CORS,Failed to fetch, orERR_BLOCKED_BY_CLIENT. - Jump to: Fixes → The browser request failed before it reached your backend.
- Menu path: in Chrome/Edge/Firefox, press
-
If none of the above matched, test one request directly against your backend endpoint.
- Replace the URL with your actual chat endpoint:
curl -i -X POST https://your-domain.example/api/chat -H 'Content-Type: application/json' -d '{"message":"Say hello"}'- This is your problem if the endpoint returns a non-
200status, hangs, or returns an app-specific error message. - Jump to the fix section that matches the returned error.
Fixes
Invalid, expired, or missing AI provider API key
- In your provider dashboard, create a new API key if the old one is revoked or expired.
- In your hosting dashboard, update the environment variable used by your app. Common names:
OPENAI_API_KEY=your_new_key_here ANTHROPIC_API_KEY=your_new_key_here - Then redeploy or restart the app from your hosting dashboard. If you have shell access:
export OPENAI_API_KEY='your_new_key_here' systemctl restart your-app - If your app stores secrets in a
.envfile:sed -i 's/^OPENAI_API_KEY=.*/OPENAI_API_KEY=your_new_key_here/' .env - Verify it worked:
curl -i -X POST https://your-domain.example/api/chat -H 'Content-Type: application/json' -d '{"message":"hello"}'
Rate limit or quota exhausted
- In the provider dashboard, add payment details, raise the usage cap, or wait for the limit window to reset.
- If your app sends too many requests at once, lower concurrency (how many requests run in parallel) in your worker or server config. Example Node.js queue setting:
{"aiRequestConcurrency":2} - Add simple retries with backoff (a short delay before retrying) for
429responses. Example pseudocode config:{"retryOn":[429],"retries":3,"backoffMs":1000} - Verify it worked: send 2-3 test messages in a row and confirm your provider dashboard no longer shows new
429errors.
Your backend or webhook timed out before the model replied
- Increase the timeout in your reverse proxy or app server. For nginx:
location /api/chat { proxy_connect_timeout 60s; proxy_send_timeout 120s; proxy_read_timeout 120s; send_timeout 120s; } - Reload nginx:
nginx -t && systemctl reload nginx - If your app platform has a request timeout setting, raise it in the service settings page.
- If responses are long, enable streaming in your app so the user sees output sooner and the connection stays active.
- Verify it worked:
You should stop seeing fresh timeout lines during a new test.
grep -Ei '504|ETIMEDOUT|timeout' /var/log/nginx/error.log /var/log/* 2>/dev/null | tail
A moderation, guardrail, or routing rule blocked the request
- Open your app's moderation or workflow rules and look for conditions that match too broadly, such as blocking all messages with links, code, or certain keywords.
- If you use a routing rule, confirm every route ends in a response action or fallback. A safe fallback pattern is:
{"route":"default","action":"send_to_ai"} - If you keep rules in config, narrow the blocked patterns. Example:
{"blockPatterns":["password reset token"],"allowUnknown":true} - Verify it worked: resend one previously blocked message and confirm it now appears in the conversation log as processed, not filtered.
The browser request failed before it reached your backend
- If Developer Tools shows
ERR_BLOCKED_BY_CLIENT, disable ad/privacy extensions for your site and test again. - If it shows a CORS error (the browser blocked a cross-site request), add your website origin to the backend allowlist. Example Express config:
app.use(cors({ origin: ['https://www.your-domain.example'] })) - If the frontend points to the wrong API URL, fix the environment variable in your hosting dashboard. Example:
NEXT_PUBLIC_API_URL=https://api.your-domain.example - Verify it worked: in Developer Tools → Network, the
POSTrequest should return200or your normal success status instead of failing in the browser.
Provider outage or degraded service
- Confirm the incident on the provider status page.
- Temporarily show a friendly fallback message in your app instead of leaving users with silence. Example response text:
The assistant is temporarily delayed. Please try again in a few minutes. - If your app supports a secondary provider, switch the model/provider in your app settings or config. Example environment variables:
AI_PROVIDER=backup AI_MODEL=backup-model-name
⚠️ Switching providers can change output style, cost, and data handling. Review your privacy and compliance requirements before enabling a backup provider.
- Verify it worked: new requests should either succeed through the backup path or return the fallback message immediately instead of hanging.
Prevention
- Add an uptime check for your chat endpoint every minute.
curl -fsS https://your-domain.example/api/health || echo 'chat endpoint failed' - Alert on
401,429, and5xxspikes in your logs. Example grep for a simple cron job:grep -E ' 401 | 429 | 5[0-9][0-9] ' /var/log/nginx/access.log | tail -100 - Add a startup check that fails fast when the API key is missing.
if (!process.env.OPENAI_API_KEY) { throw new Error('OPENAI_API_KEY is missing') } - Pin and document your timeout settings so deploys do not reset them.
proxy_read_timeout 120s; - Add a CI smoke test that posts a tiny prompt to a non-production endpoint after deploy.
curl -i -X POST https://staging.your-domain.example/api/chat -H 'Content-Type: application/json' -d '{"message":"health check"}' - Log blocked moderation/routing decisions separately from provider failures so "silent" drops are visible.
{"event":"message_blocked","reason":"policy_rule","conversationId":"12345"}
This article was written by an AI system and published pending human review. Verify anything you intend to act on.
Have a project in mind?
Get an instant AI price estimate for it, or talk directly to our team.
One email a month on what we learn building with AI