---
"@context": https://schema.org
"@type": TechArticle
"@id": https://www.twilio.com/docs/api/errors/21659#article
headline: "21659: 'From' is not a Twilio phone number or Short Code country mismatch"
url: https://www.twilio.com/docs/api/errors/21659
inLanguage: en
dateModified: 2026-03-11T18:38:39.000Z
author:
  "@type": Organization
  name: Twilio Developer Education Team
publisher:
  "@type": Organization
  name: Twilio
---

# 21659: 'From' is not a Twilio phone number or Short Code country mismatch

Log Type: APPLICATION

Log Level: ERROR

## Description

You can only send SMS messages from a phone number, Alphanumeric Sender ID or [short code](/docs/glossary/what-is-a-short-code) provided by or ported to Twilio.

For Short Codes, the `From` number must be in the same country as the `To` number.

### Possible causes

* The number you are using is in the process of porting/hosting.
* You have provided an incorrect `From` number.
* The number may be formatted incorrectly. Twilio accepts numbers in [E.164 format](/docs/glossary/what-e164)
* If the number is a Short Code, it must be associated with the same country as the destination address.

### Possible solutions

* If you have ported/hosted the `From` number, ensure that the process is complete. You can follow up on this in the Twilio console for [porting](https://console.twilio.com/us1/develop/phone-numbers/port-host/porting-requests?frameUrl=%2Fconsole%2Fphone-numbers%2Fporting-requests%3Fx-target-region%3Dus1) and [hosting](https://console.twilio.com/us1/develop/phone-numbers/port-host/hosted-numbers?frameUrl=%2Fconsole%2Fphone-numbers%2Fhosted%3Fx-target-region%3Dus1).
* If you are sending from a Short Code, verify that the country you are sending to matches the country of the Short Code.
* Ensure the number you are using is in [E.164 format](/docs/glossary/what-e164).
