ConnectButton
The ConnectButton
component unlocks all of thirdweb’s login, onboarding, and blockchain interaction capabilities via a customizable and secure interface.
When logged out, the ConnectButton
offers users secure login methods with email, phone, socials, and external wallets. When logged in, the ConnectButton enables users to send and receive funds to their account, purchase crypto with onramps, and execute transactions within your application.
Get started
Automatic Setup
Starter templates are pre-configured with ConnectButton
to help you get started quickly.
In your CLI, run:
Select a framework: Next, Vite, or Expo. The command will create a new directory with starter code and the necessary dependencies installed.
Manual Setup
Install
Install the Connect SDK
Obtain Client Id
On the thirdweb dashboard, navigate to settings to create an API Key to obtain a Client Id.
Add ConnectButton component
In your application, initialize and add the
ConnectButton
component by passing in your Client Id.Configure login options
Configure the
wallets
property to enable various login options such as email & phone number, socials, and EOAs such as MetaMask or Phantom.Customize theme
Use the default light and dark theme or override the default theme to customize the appearance of the modal.
To fully customize and learn more about the ConnectButton
properties, view the full reference.
Example of how to use ConnectButton component created in a Next application.