SUPPORT.TWILIO.COM END OF LIFE NOTICE: This site, support.twilio.com, is scheduled to go End of Life on February 27, 2024. All Twilio Support content has been migrated to help.twilio.com, where you can continue to find helpful Support articles, API docs, and Twilio blog content, and escalate your issues to our Support team. We encourage you to update your bookmarks and begin using the new site today for all your Twilio Support needs.

How do I restrict API access to specific IP addresses?

Objective

This article helps you choose how strictly Twilio enforces your IP access control list, so that API requests to your account are only accepted from IP addresses you trust.

 

Product

Twilio Console

 

Environment

Twilio Console

 

Procedure

  1. In the Twilio Console, select Settings in the left sidebar.
  2. Under Account settings, select IP ACL.
  3. Add at least one IP address or range to the IP addresses list first, if you have not already.
  4. In the Enable IP ACL section, choose one of the four options:
  5. Off, no IP restriction is applied.
  6. Dry run mode (for testing), requests are evaluated and logged but not blocked.
  7. Auth Token traffic only (Legacy support), only requests authenticated with an auth token are restricted.
  8. All API traffic (Recommended), every API request is restricted.
  9. Read the confirmation dialog that appears and confirm the change.
  10. A confirmation appears describing the mode you enabled, for example, "IP access control enabled for Auth Token traffic."

 

Additional Information

  • The selected option does not change until you confirm the dialog, so you can back out safely.
  • Dry run mode and All API traffic need at least one IP address on the list. If the list is empty, an Add IP addresses prompt appears instead of the confirmation, explaining that "For IP ACL selection to take effect, you must add at least one IP address." Selecting the prompt's action takes you straight to Add IP address.
  • Off and Auth Token traffic only can be confirmed with an empty list.
  • If a mode that needs IP addresses is already active while the list is empty, the page shows the same warning until you add one.
  • Start with Dry run mode to confirm your legitimate traffic would pass before enforcing on all API traffic.
  • If the change cannot be saved, the page reports "Failed to update IP ACL mode. Please try again."

 

This content was generated by AI and reviewed, edited, and verified by a human.

Have more questions? Submit a request
Powered by Zendesk