Skip to main content
Get a working CKB application running in a few minutes. You can either scaffold a new project with create-ccc-app or add CCC manually to an existing project.

Option 1: Bootstrap with create-ccc-app

create-ccc-app scaffolds a new CCC project with your chosen framework template, pre-configured with the right packages, TypeScript settings, and a working example.
Follow the prompts to select a framework template, then open the generated project.

Option 2: Manual setup

If you are adding CCC to an existing project, follow these steps.
1

Install the package

Install the package that matches your environment. For a React app:
See Installation for the full list of packages and when to use each one.
2

Check your tsconfig.json

CCC uses Package Entry Points for tree-shaking. Make sure moduleResolution in your tsconfig.json is set to node16, nodenext, or bundler:
tsconfig.json
If moduleResolution is set to node or classic, TypeScript will report errors like Property '*' does not exist on type 'typeof import(...)'.
3

Wrap your app with Provider

ccc.Provider manages wallet state and renders the connector UI. Add it at the root of your React application:
app.tsx
If you use React Server Components (e.g. Next.js App Router), add "use client" at the top of any file that imports or renders ccc.Provider.
4

Connect a wallet

Use the useCcc hook to open the wallet selector and read the connected signer:
wallet-button.tsx
Calling open() displays the built-in wallet selector. CCC automatically detects available wallets in the user’s browser.
5

Send CKB

Use the useSigner hook to get the active signer, then compose and broadcast a transaction:
send-ckb.tsx
ccc.fixedPointFrom("100") converts a human-readable CKB amount to the on-chain unit (Shannon, where 1 CKB = 10⁸ Shannon). completeInputsByCapacity and completeFeeBy automatically select inputs and calculate fees — you only need to describe what you want in the outputs.

Next steps

Installation

Learn about all available packages and advanced import options.

Connect wallets

Customize the wallet connector and filter supported wallets.

Send CKB

Dive deeper into transaction composition and fee handling.

Playground

Experiment with CCC live in your browser — no install needed.