CertiK Prover user guide
Quick start
CertiK Prover checks Solidity code against specifications—precise statements of what the code must do—for every allowed input, not only the cases a test happens to try. Use it from the command line on your own machine, or through the web app for projects CertiK verifies with you.
- You will learn
- How to install the command-line tools, run a first check, and sign in to the web app.
Choose how to start
Command line
Install csol and csol-project, and check contracts on your own machine while you write them. Your code stays local.
Web app
Sign in with your CertiK Account to review verification results for the projects CertiK shares with your organization.
Set up the web appCommand line
The CertiK Prover package installs two commands: csol checks one Solidity entry file, and csol-project checks every entry file listed in a project file.
Check the prerequisites
You need Node.js 22.12 or newer with npm, on macOS, Linux (x64 or ARM64), or Windows x64.
Terminal node --versionInstall the package
CertiK provides the package as a file named
certikproject-csol-verifier-<version>.tgz. From the folder that contains it, install it globally with npm:Terminal npm install -g ./certikproject-csol-verifier-<version>.tgzIf you installed the older standalone
csol-projectpackage, uninstall it first, or npm stops with anEEXISTerror. Do not use--force.Terminal npm uninstall -g csol-projectConfirm the installation
Terminal csol --version csol-project --versionBoth commands print the package version. The first
csolrun may download and cache a Java runtime and the Z3 solver, so it needs network access once.Write a contract with a specification
Save this as
Counter.sol. The lines that start with//@are its specification: after a successful call,valuehas grown by exactly one, the function returns the new value, and nothing else changes. Basics explains where specifications go.Counter.sol // SPDX-License-Identifier: MIT pragma solidity ^0.8.20; contract Counter { uint256 public value; //@ ensures value == \old(value) + 1; //@ ensures \result == value; //@ assignable value; function increment() external returns (uint256) { value += 1; return value; } }Check it with
csolRun
csolon the file. CertiK Prover checks every specification and ends with a summary:Terminal csol Counter.solOutput … Function 'Counter.increment' verification success. (703ms) … === Verification Summary: 1 total, 1 passed, 0 failed, 0 errors === … Verification success.Give
csolone entry file. It follows that file's imports, so you never list every file:Terminal # Wrong: a directory or a list of files csol contracts/ Counter.sol Helper.sol # Right: one entry file; CertiK Prover follows its imports csol Counter.solRead the exit code
Scripts and CI can rely on the exit code of
csolandcsol-project:Exit code Meaning 0Every checked specification passed. 1CertiK Prover found a counterexample: a specification can be violated. 2The command, the source, or its compilation failed, so nothing was checked. 3A check was inconclusive, or the verifier hit an internal error. Check a whole project with
csol-projectWhen a project has several entry files, list them in
csol-project.yamlat the project root. Each entry has anidand thepathof its entry file:csol-project.yaml schema_version: 1 entrypoints: - id: counter path: src/Counter.solRun
csol-projectfrom the project root. It checks each entry withcsoland shows live progress:Terminal csol-projectOutput Project: ./csol-project.yaml Entrypoints: 1 | Prover jobs: 1 Running counter (src/Counter.sol) ✓ counter [1/1]: █ (1.7s, pass: 1, fail: 0, timeout: 0) No failures or errors. Exit: 0Each run saves its results in a new folder under
verification-runs/, with one subfolder per entry. Add--jobs 4to check up to four entries in parallel;csol-project --helplists every option.verification-runs/csol-project-<timestamp>-<pid>/ ├── summary.json └── 0001-counter/ ├── result.json ├── events.jsonl └── stderr.log
csol and csol-project run CertiK Prover on your machine. They do not sign in or upload your code.
Web app
In the web app, CertiK Prover runs on CertiK's servers against the project revisions CertiK has set up with you. You can review every result, counterexamples included.
Accept your CertiK Account invitation
CertiK invites you to CertiK Account by email. Follow the link to create your account, or sign in if you already have one. The invitation adds you to your organization, and your organization is what CertiK grants access to.
Sign in to CertiK Prover
Open CertiK Prover, select Login, then Continue with CertiK Account. If you belong to several organizations, choose the one CertiK invited you to.
Signing out of CertiK Prover leaves your CertiK Account signed in.
Open your project
After sign-in, the Projects page lists each verified project with its latest outcome. If it shows No accessible projects, ask your CertiK contact to grant your organization access.
Review the results
On the project page, open Results for a finished task to see every entry and its outcome. Each failed specification comes with its counterexample.
A running task shows progress, not a result. Read the outcome only after the task finishes.
Run the full examples
Every code sample and playground on this page is a complete contract in the CertiK Prover Server Tutorial project, where CertiK Prover runs it on the server. Sign in and open an entry's results to see the real run behind each simulated one.