Login with X (Twitter)
Let users sign in to your app with their X/Twitter account
Let users sign in to your app with their X/Twitter accounts. They’ll share their username, name, profile picture, and email.
You’ll need to set up a few things in X first, then add those settings to Create.
Before You Start
Make sure you have:
A Create project with User Accounts turned on
Your app running on a custom domain through Create’s domain setup
Overview
Set Up an X App
Create an app in X
Add to Create
Add your X App’s Client ID/Secret in Create
Add the X Login UI to your sign in pages
Make the page look how you want
Test flow
Make sure login works
X Setup
Access X Developer Portal
-
Go to X Developer Portal
-
Sign in with your X account
-
Click “Create an App”
Apply for Developer Account
-
If you don’t have a developer account, you’ll need to apply
-
Fill out the required information about your use case
-
Submit your application
Choose Developer Plan
-
Review the available developer plans
-
You can sign up for a Free account if you prefer
-
Select your plan and continue
Accept Developer Agreement
-
Review the developer terms
-
Describe your app’s purpose and that you’re using Login with X
-
Accept the terms to proceed
Create Project
-
Once approved, navigate to your dashboard
-
Click “Create Project” to begin
Name Your Project
-
Choose a descriptive name for your project
-
This is for internal organization
-
Click continue
Select Use Case
-
Choose the primary use case for your app
-
This helps X understand how you’ll use their API
Add Project Description
-
Provide a detailed description of your project
-
Explain how you’ll use X’s features
-
Be specific about your Login with X implementation
Name Your App
-
Choose a user-facing name for your app
-
This will be visible to users during sign in
Skip Initial Tokens
-
You’ll see initial Keys & Tokens
-
These include API Key, API Key Secret, and Bearer Token
-
You can skip these for now - click “App Settings”
Configure User Authentication
-
In App Settings, find “User authentication settings”
-
Click “Set up”
Set App Permissions
-
Choose your app permissions level
-
You can request read/write permissions
-
Optionally request email access for users if you want your app to send users emails
Configure App Type
-
Select “Web App” as your app type
-
This enables web-based authentication
Add App Information
-
Enter your callback URL:
https://www.your-domain.com/api/auth/callback/twitter
-
Add your website URL:
https://www.your-domain.com
-
Add privacy policy URL:
https://your-domain.com/privacy
-
Add terms of service URL:
https://your-domain.com/terms
Must include:
-
https://
protocol -
www
prefix for callback and website URLs -
Exact domain for the app used in Create’s custom domain settings
You can use services like Termly to generate these required policy documents and host them on pages in your Create app
Access Keys and Tokens
- After saving settings, go to “Keys and Tokens” section
Copy OAuth Credentials
-
Under OAuth 2.0 Client ID and Client Secret
-
Copy the Client ID
-
Generate and copy the Client Secret
-
Save both values - you’ll need them in Create
Keep your Client Secret secure - never share it publicly
Add to Create Project
Enable User Accounts
You have two options:
-
Prompt Create with “Let users sign in”
-
Enable User Accounts from the logo menu
Access Project Settings
-
Click the 3-dot menu at the top of the chat
-
Select “Project Settings”
Enable Login with X
-
Navigate to the Authentication section
-
Find Login with X toggle
-
Turn it on
Add X Credentials
-
Paste in your Client ID
-
Paste in your Client Secret
-
Click Save
Add Sign In UI
-
Return to the chat
-
Prompt Create with “Add Login with X as an option”
-
Create will update your sign-in pages automatically
Publish Your App
-
Click the Publish button
-
Review your changes
-
Publish to make the Login with X feature live
Testing
-
Publish your changes
-
Open your app in a new incognito window
-
Go to the sign in page
-
Try signing in with X
-
Check the auth_users table to see your new user
Troubleshooting
FAQ
See Also
Was this page helpful?