Privacy Protocol

The best way to add privacy to your

dApp

npm i privacy-protocol

Secure. Simple. Seamless.

Everything you need to easily and efficiently integrate privacy into your application.

Ship in Minutes, Not Months

Skip the steep learning curve of ZK circuits. Integrate enterprise-grade privacy with just few lines of code.

Tap Into Deep Liquidity

Don't fragment liquidity or redeploy contracts to a new chain. Wrap your existing dApp on Ethereum/Arbitrum in minutes without moving a single asset.

Audit-Ready Compliance

Protect your protocol from regulatory risk with built-in hooks for View Keys and Proof-of-Innocence, preventing illicit usage.

Retain User Sovereignty

Give users what they want: absolute control. By removing centralized provers, you eliminate the single point of failure and trust.

Unbroken Composability

Your dApp keeps working exactly as it does today. Uniswap swaps, Aave deposits, DAO votes, Polymarket trades, all function normally inside the privacy shield.

Zero User Friction

No more 'withdraw-to-mix' headaches. Users enjoy a fluid experience where privacy is a background feature, not a hurdle.

How It Works (For Developers)

Privacy Protocol is the modular privacy layer for the EVM. Powered by zero-knowledge proofs, it enables developers to seamlessly integrate privacy into their existing and new dApps without sacrificing composability or breaking the UX of their dApps.

01

Install and Enable

Install the SDK to wrap standard wallets. Enable shielded transactions with zero changes to your backend logic.

02

Client-Side Proving

The SDK abstracts ZK complexity, generating local proofs to authorize intents without revealing the signer's identity.

03

Relayed Execution

Proofs are verified on-chain. The protocol executes calls to your contract via a fresh, ephemeral proxy.

04

Composable Settlement

Execute standard logic (mint, swap, vote etc.). Outputs are automatically routed back to the user's shielded balance.

How It Works (For Users)

Created with your user's experience in mind. Privacy Protocol acts as an invisible shield over your existing workflow. Instead of navigating complex mixers or fragmented Layer 2s, users can interact with their favorite dApps with the same speed and ease they are used to, all while their identity and actions remain mathematically private.

01

Shield Your Assets

Deposit your tokens into the Privacy Pool. Your funds are secured, and you receive a private, encrypted 'note' that proves your ownership without revealing it.

02

Masked Interaction

When you swap, trade, vote, bet or any other action, a Zero-Knowledge proof authorizes the move. The protocol assigns a fresh, temporary address to execute the action on your behalf.

03

Private Settlement

Winnings or swapped tokens are tracked via that temporary address and automatically routed back to your private balance—completely untraceable to outsiders.

04

Anonymous Withdrawal

Withdraw a portion or all of your funds to any wallet. The link between your original deposit and your exit is mathematically broken.

Features

Complete suite of zero-knowledge primitives designed to make privacy as standard as a token transfer.

Universal SDK

A lightweight npm package that integrates into your existing frontend. No contract changes, no asset migration—just install and wrap your provider.

Browser-Native Proving

Utilizes Aztec's bb.js and Noir to generate SNARKs directly in the browser memory, eliminating the need for trusted server-side proving.

Ephemeral Relayer Network

A decentralized network of relayers that deploy fresh proxy contracts for every transaction, ensuring on-chain unlinkability.

Encrypted UTXO State

Manages user balances using an encrypted Note model, allowing for precise state updates and partial spending.

Nullifier Registry

On-chain storage of spent nullifiers to mathematically prevent double-spending without revealing the spender's identity.

Yield-Aware Vaults

Smart contract vaults that hold the shielded assets and can be extended to earn yield on Aave/Compound while funds sit idle.

Quick Start Guide

Get your dApp privacy-enabled in minutes with just a few lines of code.

Step 1

Install the SDK

Install the SDK and core dependencies to get started.

npm i privacy-protocol ethers
Step 2

Set up SDK

Initialize with provider and pool address. Relayer transport is resolved by default.

import { useDeposit, useExecuteAction } from "privacy-protocol/hooks";

const config = {
  poolAddress,
  provider,
  signer,
};
Step 3

Use Hooks

Deposit funds and execute private actions. Relay lifecycle resolves from queued to submitted to confirmed.

const [privateTxHash, setPrivateTxHash] = useState<string>();
const { deposit } = useDeposit(config);
const { executeAction } = useExecuteAction(config);
const { data: details } = usePrivateTransactionDetails({
  ...config,
  txHash: privateTxHash,
});

const depositResult = await deposit({ token, amount });
const result = await executeAction({
  token,
  amount,
  target,
  data,
  secret: depositResult.secret,
  nullifier: depositResult.nullifier,
  amountInPool: amount,
});
setPrivateTxHash(result.txHash);