Twilio API domain migration guide
Twilio is deprecating the api.REGION.twilio.com domain pattern (where REGION is ie1, au1, br1, de1, jp1, sg1, or us2). These domains process all requests in US1 regardless of the region code and will stop working on April 28, 2026.
| Migrate from | Migrate to |
|---|---|
api.ie1.twilio.com, api.au1.twilio.com, api.br1.twilio.com, api.de1.twilio.com, api.jp1.twilio.com, api.sg1.twilio.com, api.us2.twilio.com | api.twilio.com |
SDK usage with region parameter only | SDK usage without region, or with both edge and region |
api.us1.twilio.com remains valid. If you need Twilio to primarily process and store data outside the US (in Ireland or Australia), see Understanding Edge Locations.
Search your code, configuration files, and infrastructure for the deprecated domains (api.ie1.twilio.com, api.au1.twilio.com, api.br1.twilio.com, api.de1.twilio.com, api.jp1.twilio.com, api.sg1.twilio.com, api.us2.twilio.com).
Twilio can process your data in the United States, Ireland, or Australia. Identify the regions your applications need.
If you make API requests without using a Twilio SDK (for example, with cURL or a custom HTTP client), update the domain based on where you need data processed.
-
Replace the deprecated domain with
api.twilio.com. Your existing credentials continue to work.1# Before (deprecated)2curl -X POST https://api.ie1.twilio.com/2010-04-01/Accounts/$ACCOUNT_SID/Messages.json \3-u $ACCOUNT_SID:$AUTH_TOKEN \4-d "Body=Hello from Twilio"56# After7curl -X POST https://api.twilio.com/2010-04-01/Accounts/$ACCOUNT_SID/Messages.json \8-u $ACCOUNT_SID:$AUTH_TOKEN \9-d "Body=Hello from Twilio"
Update to the Latest SDK Version
Before migrating, update to the latest version of your Twilio SDK.
Older SDK versions may not properly support the edge parameter or may have bugs related to regional routing. Updating to the latest SDK version ensures:
- Proper support for
edgeandregionparameters - Bug fixes for regional routing
- Improved error handling
Check the Twilio Helper Libraries page for the latest SDK versions.
Select your SDK language to see migration examples. If you need data processing in Ireland or Australia, see Using the Twilio REST API in a non-US Region.
Before: Deprecated pattern
1// Deprecated - region without edge routes to US only2const twilio = require('twilio');3const client = twilio(accountSid, authToken, {4region: 'ie1'5});
After: US processing
1// Correct - processes in US2const twilio = require('twilio');3const client = twilio(accountSid, authToken);4// No region parameter needed
After: Regional processing
If you are looking to use regionalized Twilio applications, see Using the Twilio REST API in a non-US Region.
1// Processes in IE1 (requires IE1 credentials and data migration)2const twilio = require('twilio');3const client = twilio(accountSid, authToken, {4edge: 'dublin',5region: 'ie1'6});
Important
When using any SDK, specifying only the region parameter without the edge parameter routes requests to US1, not the specified region. Always specify both edge and region parameters together for regional processing.
Update your DNS allowlists to include the correct domains:
Remove (deprecated domains):
1api.ie1.twilio.com2api.au1.twilio.com3api.br1.twilio.com4api.de1.twilio.com5api.jp1.twilio.com6api.sg1.twilio.com7api.us2.twilio.com
Keep or Add (US processing):
1api.twilio.com2api.us1.twilio.com (valid - processes in US)
Add (if using regional processing - IE1 and AU1 only):
1api.dublin.ie1.twilio.com2api.sydney.au1.twilio.com
Update firewall rules, security groups, proxies, and load balancers that reference the deprecated domains.
Info
Twilio uses a CDN, so IP addresses may vary. Use domain names in allowlists rather than IP addresses when possible. See Network Connectivity Requirements for IP ranges.
Test in a development environment before deploying to production. If using regional processing, confirm your regional credentials work. Deploy gradually and monitor error rates before completing the migration.
Cause: Using US credentials with regional endpoints, or vice versa.
Solution: Ensure you're using region-specific credentials for regional endpoints. See managing Regional API credentials.
1# Wrong - US credentials with IE1 endpoint2curl -u $US_ACCOUNT_SID:$US_AUTH_TOKEN \3https://api.dublin.ie1.twilio.com/...45# Right - IE1 credentials with IE1 endpoint6curl -u $IE1_API_KEY_SID:$IE1_API_KEY_SECRET \7https://api.dublin.ie1.twilio.com/...
Cause: Specifying region without edge parameter.
Solution: Always specify both edge and region together:
1// Wrong - only region specified2const client = twilio(accountSid, authToken, {3region: 'ie1' // Still routes to US!4});56// Right - both edge and region specified7const client = twilio(accountSid, authToken, {8edge: 'dublin',9region: 'ie1'10});
Cause: Firewall, proxy, or DNS resolver blocking new domain patterns.
Solution:
- Update DNS allowlists
- Update firewall rules
- Clear DNS cache:
sudo dscacheutil -flushcache(macOS) oripconfig /flushdns(Windows) - Verify DNS resolution:
nslookup api.dublin.ie1.twilio.com
Cause: Certificate mismatch or outdated certificates.
Solution:
- Update system CA certificates
- Ensure clients support SNI (Server Name Indication)
- Verify certificate chain:
openssl s_client -connect api.dublin.ie1.twilio.com:443
Contact Twilio Support for assistance with your migration.