---
"@context": https://schema.org
"@type": TechArticle
"@id": https://www.twilio.com/docs/api/errors/20159#article
headline: "20159: Invalid Signature"
url: https://www.twilio.com/docs/api/errors/20159
inLanguage: en
dateModified: 2026-03-19T15:18:23.000Z
author:
  "@type": Organization
  name: Twilio Developer Education Team
publisher:
  "@type": Organization
  name: Twilio
---

# 20159: Invalid Signature

Log Type: TWILIO

Log Level: ERROR

## Description

This error occurs when the JWT provided to the Twilio API has an invalid or mismatching signature.

### Possible causes

The public key referenced in the JWT does not match the actual private key used to sign the token.

### Possible solutions

* Ensure the private key used to sign the JWT corresponds to the public key identifier referenced in the token.
* If needed, validate the JWT's structure and signature using standard JWT tooling before retrying.

#### Additional resources

* [Access Tokens](/docs/iam/access-tokens)
* [API keys overview](/docs/iam/api-keys)
* [Public Key Client Validation Quickstart](/docs/iam/pkcv/quickstart)
