Moving from a public Tweet to a private conversation

When interacting with a customer on Twitter, you might want to take the conversation from the public timeline to a private Direct Message.

To make this transition easier, you can include a specially-formatted link in a Tweet, and we will automatically transform that link into a simple call-to-action that guides users straight into composing a new Direct Message to you, with the public Tweet visible for context. 

How does it work?

Using this feature is easy, but requires that your account settings are set to “Receive Direct Messages from Anyone” (Settings > Security and Privacy > Privacy). You also need to include a link in your Tweet using the following format:

https://twitter.com/messages/compose?recipient_id={your account’s numeric user ID}

Locate your User ID here.

That’s it! When you post the Tweet with that URL, the "Send a private message" call-to-action will appear in supported clients. Other clients will just see a deep link that is fully-functional.

Are there other parameters that I can use in these deep links besides specifying recipient?

You can add a parameter &text={default text} to the end of the URL, and replace {default text} with the URL encoded text you’d like to pre-populate in the user’s compose box.

For example, if you need a specific piece of information from the user, you could have that label appear in the user’s compose box for additional context (e.g., “Confirmation Number:”).

Are there other ways to use this feature without pasting a link each time?

While all you need for the call-to-action to display is to include the correctly-formatted link in your Tweet, many Twitter Official Partners and other Twitter developer ecosystem tools have made it simple to include these links in your Tweets with the click of a button.

How does this feature impact the character count in my Tweets?

Twitter will shorten the deep link in your Tweet using t.co, so the link will occupy 22 characters (the same amount as any t.co link). This is the case whether the call-to-action renders or does not render.

For businesses that use a tool to create the link as a media upload, no characters will be deducted from the 280 character limit.

Does the deep link for a Direct Message work outside of Twitter?

Yes! The URL for a deep link to a Direct Message will attempt to open Twitter with a Direct Message compose window open if clicked from outside of Twitter.

Why am I not seeing the formatted call-to-action in my Tweet reply?

This may occur for a couple of reasons. You might not have configured your settings to Receive Direct Messages from anyone, or you may be viewing the Tweet in a third-party/unsupported Twitter client. Additionally, older Twitter clients may not render the call-to-action and only display the link.

Why does the link I pasted in get removed and replaced with the “Send a private message” call-to-action?

The URL will be stripped out of the Tweet display if it is located at the end of the Tweet. If the URL is in the middle or the beginning of the Tweet, the URL will still display in the Tweet. Regardless of if the URL is stripped out or not, the “Send a private message” call-to-action will display.

Ready to get started?