<div align="center">
<img src="circom-logo-black.png" width="460px" align="center"/>
</div>

[![Chat on Telegram][ico-telegram]][link-telegram]
[![Website][ico-website]][link-website]
[![GitHub repo][ico-github]][link-github]
![Issues](https://img.shields.io/github/issues-raw/iden3/circom?color=blue)
![GitHub top language](https://img.shields.io/github/languages/top/iden3/circom)
![Contributors](https://img.shields.io/github/contributors-anon/iden3/circom?color=blue)

[ico-website]: https://img.shields.io/website?up_color=blue&up_message=circom&url=https%3A%2F%2Fiden3.io%2Fcircom
[ico-telegram]: https://img.shields.io/badge/@iden3-2CA5E0.svg?style=flat-square&logo=telegram&label=Telegram
[ico-github]: https://img.shields.io/github/last-commit/iden3/circom?color=blue

[link-website]: https://iden3.io/circom
[link-telegram]: https://t.me/iden3io
[link-github]: https://github.com/iden3/circom

---

# <div align="center"><b>[Start here](https://iden3.github.io/circom/getting-started/installation/)</b></div>

---

# &#9888; Important deprecation note

Current `circom` is a compiler written in Rust. The old `circom` compiler written in Javascript will be frozen, but it can still be downloaded from the [old circom repository](https://github.com/iden3/circom_old).

---

# About the circom ecosystem

The circom compiler and its ecosystem of tools allows you to create, test and create zero knowledge proofs for your circuits.

## circom

`circom` is a compiler written in Rust for compiling circuits written in the `circom` language.
The compiler outputs the representation of the circuit as constraints and everything needed to compute different ZK proofs. 

## circomlib

With `circom`, it is possible to create large circuits by combining smaller generic circuits called `templates`. The `circomlib` is a library of `circom` templates that contains hundreds of circuits such as comparators, hash functions, digital signatures, binary and decimal convertors and many more. You can also create your custom templates, but before start coding, we recommend you to take a look at our already created templates.

The package already contains tests for circuits available in the `circomlib`.
The package also installs the npm packages `circomlibjs`, `circom_tester` and `ffjavascript` as dependencies.

## circomlibjs

`circomlibjs` is a Javascript library that provides programs to compute the witness of several circuits of `circomlib`.
This library is used to check that the witness computed 
using the wasm or c code generated by `circom` form many circuits in the `circomlib` match the ones generated by the corresponding Javascript program in `circomlibjs`.

The package includes these programs in the src directory. In the 
test directory it includes its own tests. In the tools directory it includes programs to precompute some needed parameters.

## circom_tester

The `circomtester` is a npm package that provides tools for testing `circom` circtuits.

## ffjavascript

The `ffjavascript` is a npm package with Javascript code to perform finite field operations in Javascript. 

## snarkjs

`snarkjs` is a npm package that contains code to generate and validate ZK proofs from the artifacts produced by `circom`. 

# Visual summary <a id="visual-summary"></a>

![](https://gblobscdn.gitbook.com/assets%2F-MDt-cjMfCLyy351MraT%2F-ME35kSLplV3Z39JJsLE%2F-ME37Q2MlDc67k0-jzQS%2Fcircomsnarkjs.png?alt=media&token=4b1b1c11-a1d4-4048-8c3a-0c7b02f4930a)

