Sending

SendGrid error codes explained, and how to fix each one

Short answer

SendGrid API errors come back as an HTTP status plus an errors array with a message and the field at fault. 400 is a malformed request, 401 a missing or invalid API key, 403 usually an unverified sender identity or a temporarily blocked account, 413 content too large, 429 too many requests and 500 a server error. Codes like 550 and 451 are different: they come from the recipient's mail server and show up in bounce and deferred events.

Last checked 16 November 2026

A SendGrid error is either an API error, returned straight away when you call /v3/mail/send, or a delivery error, reported later when the recipient’s mail server rejects or delays the message. API errors are HTTP statuses (400, 401, 403, 413, 429, 500) with an errors array that names the problem. Delivery errors are SMTP codes (550, 451, 421 and so on) that you see in bounce, blocked and deferred events. Fix the first kind in your code or account; read the second kind to learn what the receiving server objected to.

How SendGrid reports API errors

According to the Mail Send reference (checked 16 November 2026), error responses share one shape: an errors array whose items have a message, a field when one field caused the problem, and sometimes a help link, plus an optional top-level id.

{
  "errors": [
    {
      "message": "a description of the problem",
      "field": "personalizations.0.to",
      "help": "a link to the relevant docs"
    }
  ]
}

Always log the whole array. The field value turns a vague 400 into an exact line to fix.

SendGrid API error codes

From Twilio’s v3 API responses page and the Mail Send reference (checked 16 November 2026):

Status Meaning What to do Retry?
202 Accepted for delivery Nothing; track delivery by events No
400 Malformed or invalid request Read field and fix the body No
401 Authentication missing or invalid Check the API key and header No
403 Not permitted: unverified sender identity, or account temporarily blocked Verify the sender or domain No
404 Not found Check the URL No
405 Method not allowed Use POST for mail send No
406 Accept header missing Send Accept: application/json No
413 Content too large Shrink attachments or the body No
429 Too many requests Back off and retry Yes
500 Server error Back off and retry Yes

400 Bad Request

The body is not valid for Mail Send. Common causes include an empty personalizations array, a missing from, no content and no template, or an invalid email address. Mail Send also has hard limits: up to 1,000 personalizations, 1,000 each in cc, bcc and reply_to_list, at most 10 categories of up to 255 characters, and send_at no more than 72 hours ahead. Keep requests inside those limits.

401 Unauthorized

The API key is missing, mistyped, deleted, or the header is wrong. The header must be Authorization: Bearer <key>. Check you are not loading an old key from a stale environment variable, and that the key has Mail Send permission if you use restricted keys. If you use EU regional subusers, the API host is api.eu.sendgrid.com, per Twilio’s bounce API docs.

403 Forbidden

Twilio lists two causes. The common one is a from address that is not a verified sender identity: verify the single sender, or better, authenticate the whole domain with DKIM. The other is that SendGrid has temporarily blocked the account from sending after repeated bad requests, so fix whatever is generating the errors and wait.

413 Content Too Large

The request is too big, usually because of attachments. Link to large files instead of attaching them; it also helps deliverability.

429 Too Many Requests

You are sending faster than allowed. Slow down, batch recipients into personalizations where it makes sense, and retry with exponential backoff and jitter.

500 Internal Server Error

A problem on SendGrid’s side. Retry with backoff. If it persists, check Twilio’s status page for SendGrid components, or read our guide on checking whether SendGrid is down.

Delivery errors: 550, 451 and friends

When the API returns 202 but the email does not arrive, look the message up in Email Activity or your Event Webhook data. Twilio’s event reference describes:

  • bounce with type: "bounce": the receiving server permanently refused the message. The SMTP reply is often a 550 (for example 550 5.1.1, mailbox does not exist).
  • bounce with type: "blocked": a temporary refusal, often for content or reputation.
  • deferred: the receiving server asked to try later, with codes like 421 or 451. SendGrid retries and reports the attempt count.
  • dropped: SendGrid did not send at all, with a reason such as Bounced Address, Unsubscribed Address, Spam Reporting Address or Invalid.

Each bounce also carries a bounce_classification: Invalid Address, Technical, Content, Reputation, Frequency/Volume, Mailbox Unavailable or Unclassified. That tells you whether to fix the list, your DNS, your content or your sending pace. Our SMTP error codes guide explains the 4xx and 5xx codes themselves, and SendGrid bounces covers the bounce list.

A short error-handling pattern

const res = await fetch('https://api.sendgrid.com/v3/mail/send', {
  method: 'POST',
  headers: {
    Authorization: `Bearer ${process.env.SENDGRID_API_KEY}`,
    'Content-Type': 'application/json',
  },
  body: JSON.stringify(message),
});

if (res.status === 429 || res.status >= 500) {
  // Temporary: put the email back on the queue with a backoff delay.
} else if (!res.ok) {
  const { errors } = await res.json();
  console.error('SendGrid rejected the request', errors); // fix, do not retry
}

How Mailcandor compares

Mailcandor accepts SendGrid’s v3 Mail Send request at https://api.mailcandor.com/v3/mail/send, so the same body can be sent by changing the base URL and key:

sgMail.setApiKey(process.env.MAILCANDOR_KEY);
sgMail.client.setDefaultRequest('baseUrl', 'https://api.mailcandor.com');

Dynamic templates are not supported, so send rendered HTML. Mailcandor’s own errors use one shape, {"error": {"type", "message", "field"}}, and its deliverability coach explains bounces in plain English. When bounce or complaint rates put shared delivery at risk, a review opens with written reasons and 72 hours to reply before sending is restricted; immediate action is kept for phishing, malware, illegal content or harm to other senders. See switching from SendGrid, Mailcandor vs SendGrid, or pricing. Access is by request.

Questions

What does SendGrid error 403 mean?

Twilio's docs say a 403 means the From address is not a verified sender identity, or the account is temporarily blocked from sending after repeated bad requests. Verify the sender or domain, then stop sending invalid requests.

What does SendGrid error 401 mean?

Authentication is missing or invalid. Check that the Authorization header is 'Bearer' followed by a current API key, that the key was not deleted, and that it has Mail Send permission.

What is SendGrid error 550?

550 is not a SendGrid API error. It is an SMTP rejection from the recipient's server, often meaning the mailbox does not exist or the message was refused by policy. It appears in bounce events and the bounce list.

What does SendGrid error 451 mean?

4xx SMTP codes such as 451 are temporary failures from the receiving server. SendGrid reports them as deferred and retries delivery, so usually you only need to watch whether it eventually delivers or bounces.

Where can I see SendGrid error logs?

API errors come back in the HTTP response, so log the errors array in your code. Delivery problems such as bounces, drops and deferrals appear in Email Activity and through the Event Webhook.

Should I retry SendGrid errors?

Retry 429 and 500 with exponential backoff. Do not retry 400, 401, 403 or 413 until you have fixed the request, because they will fail again.

Related

Send with someone on your side.

Unlimited domains on every plan, a person before any block, and 3,000 emails a month free. Tell us what you send and we set you up within one business day.