Skip to main content
Twilio is a cloud communications platform that lets your app reach users by phone. The Twilio connector lets your Lovable app send SMS and MMS, place voice calls, verify phone numbers, and message over WhatsApp through your own Twilio account. It works well for apps that need real-time text updates, phone verification, or messaging-based workflows. Twilio is available as an app + chat connector: one shared connection that works in the chat while you build and in your published apps. With Twilio, your app can:
  • Send and receive SMS and MMS messages
  • Make and manage voice calls
  • Support WhatsApp messaging flows
  • Validate and look up phone numbers
Twilio is a good fit when your app needs to communicate with users by phone or text, rather than only through in-app notifications or email.

Common use cases and example apps

These examples show what you can build with Twilio, each with a prompt to start from.

How to connect Twilio

Who can create Twilio connections depends on your plan and workspace settings. App + chat connectors are available by default on Free, Pro, and Business plans. On Enterprise plans, they are effectively disabled at first: Who can create connections and clients defaults to No one until an admin changes it in Connectors → Admin settings → App + chat connectors. You can create multiple Twilio connections using different API keys, which is useful for separating environments (for example, development and production) or managing different Twilio accounts. When the connection is created, you can link it to the projects where you want to use it. Anyone building in a project can ask Lovable in chat to link their project to it.

Prerequisites

Before connecting Twilio, make sure you have:
  • A Twilio account and its Account SID
  • A Twilio phone number if your app sends SMS or MMS or makes calls
  • A Twilio API key with its SID and Secret. A Standard key covers sending. To read incoming WhatsApp or MMS media, use a Main key or a restricted key with media permissions
  • The Twilio Region where your account is hosted
  • Permission to create connections in your Lovable workspace (see Who can create connections and clients)
All SMS, MMS, voice, WhatsApp, and other Twilio usage through this connector is billed directly by Twilio based on your Twilio account and plan. Billing is handled by Twilio, not Lovable.

Step 1: Create a Twilio API key

Twilio authenticates with an API Key SID and Secret instead of a single token. An API key is safer than your main Auth Token because you can revoke it independently. To create a Twilio Standard API key:
1

Open the Twilio Console

Sign in to the Twilio Console and go to Account → API keys & tokens.
2

Create the key

Click Create API key. Enter a Friendly name, for example Lovable integration. Choose the Region your account is hosted in: United States (US1) for most accounts, Ireland (IE1), or Australia (AU1). Leave Key type set to Standard and click Create API key.
3

Copy the SID and Secret

Copy both the SID (starts with SK) and the Secret. Twilio shows the Secret only once, so store it securely before leaving the page.
4

Note your Account SID

Copy your Account SID (starts with AC) from the Twilio Console home page. Twilio API keys are region-specific, so the region you pick here must match the region you select in Lovable.
Your API Key Secret functions like a password. Keep it secure and never share it publicly. You’ll need it in the next step.
Before sending production SMS traffic, enable SMS Pumping Protection and review SMS Geo Permissions in the Twilio Console so only the destination countries you need are enabled. SMS pumping is fraud in which attackers trigger large volumes of SMS to numbers they control, at your expense.
See Twilio documentation for more: Create API keys in the Twilio Console.

Step 2: Connect Twilio to Lovable

You can create multiple connections using different API keys.
1

Open Twilio in Connectors

Open Connectors and select Twilio. For the other places to open the catalog from, see Where to find connectors.
2

Add a connection

Click Add connection.
3

Configure the connection

  1. Display name: name the connection, for example Twilio Prod. This name is only used inside Lovable to identify the connection.
  2. Region: select the region you used for the API key, United States (US1) (default), Ireland (IE1), or Australia (AU1).
  3. Account SID: paste your Twilio Account SID (starts with AC).
  4. Standard API Key SID: paste the API key SID you created (starts with SK).
  5. API Key Secret: paste the Secret Twilio showed when you created the key.
4

Choose who can use this connection

Under Who can use this connection, decide who in your workspace can use the connection. You start as the only person with access:
  • Only you (default): leave the access list as is; only you can use the connection and its associated data.
  • Invite specific people: add workspace members by email; only you and the people you add can use the connection and its associated data.
  • Invite entire workspace: click Invite entire workspace to make the connection available to everyone in your Lovable workspace.
See Who can use connections and clients for more information.
5

Connect

Click Connect. Lovable verifies the credentials against the Twilio API before saving the connection.
When connected, anyone building in a project can ask Lovable in chat to link their project to Twilio (based on configured connection-level access). Your Lovable apps can then send messages, place calls, and look up numbers through Twilio.

Receiving messages and calls

Twilio delivers incoming messages, delivery status updates, and call events to a webhook URL you configure on your Twilio phone number or messaging service. These webhooks do not go through the Lovable connector gateway. When you ask Lovable to handle incoming messages, it creates a public endpoint in your project. Register that endpoint as the webhook in the Twilio Console.

Limitations

The Twilio connector cannot:
  • Receive Twilio webhooks through the connector gateway. Twilio calls a public endpoint in your app directly.
  • Call Twilio APIs other than your account’s resources on the core REST API (/2010-04-01/Accounts/{AccountSid}/...) and the Messaging, Verify, Lookups, Conversations, and Content APIs.
  • Read message media with a key that lacks media permissions. If WhatsApp or MMS photo handling fails with a Twilio permission error (code 70051), update the connection with a Main API key or a restricted key that can read message media.
  • Refresh or rotate API keys automatically. To rotate, create a new key in the Twilio Console and update the Lovable connection.
  • Support per-end-user Twilio login. Each connection represents a single Twilio account shared across all projects linked to it.

Manage your connection

Connections are managed from Connectors: select , then open the connection.
  • Unlink projects to remove access from specific projects while keeping the connection available for others. See Unlink projects from a connection for the steps.
  • Delete the connection to remove it from the workspace entirely. Deleting is permanent. It removes the credentials from all linked projects, and app features that use stop working until a new connection is added. See Delete a connection for the steps and who can delete.