Skip to main content
Scaffold Stacks supports Clarity 4, 5, and 6. New projects default to Clarity 6 with epoch 4.0.

Contents

Version and epoch mapping

clarity_version and epoch must match. Clarinet 3.23+ treats ambiguous configs as epoch 4.0. A C5 contract with epoch = "4.0" will misbehave on devnet deploy. Each contract entry in contracts/Clarinet.toml looks like:

Adding contracts

The add command writes the correct epoch into Clarinet.toml for the new contract entry. Contract templates (sip010, sip009) inherit --clarity-version (default 6).

Downgrading an existing project

If changing C6 to C5 manually:
  1. Set clarity_version = 5 and epoch = "3.4" on each affected [contracts.*] entry
  2. Regenerate deployment plans:
  3. Run stacksdapp check && stacksdapp test
  4. Redeploy
Never leave clarity_version = 5 with epoch = "4.0".

Deploy implications

Testnet and mainnet

  • Direct broadcast via @stacks/transactions
  • Works for C4, C5, and C6 when the node supports the epoch
  • No Docker required

Devnet

  • Clarity 6 requires Clarinet 3.23+ and the epoch 4.0 devnet snapshot
  • C5/C6 deploys wait for epoch burn height before broadcasting
  • Devnet settings/Devnet.toml includes PoX stacking orders required for the epoch 4.0 snapshot. Do not remove them
Run stacksdapp doctor to verify your Clarinet version.

When to use which version

After any version change, run stacksdapp generate so TypeScript bindings stay aligned.