Decentralized file vault β Secured by Ethereum, pinned to IPFS, zero intermediaries.
VaultHub is a premium Web3 application that lets you upload files to IPFS via Pinata and record ownership immutably on the Ethereum blockchain. Grant granular access to other wallet addresses, view shared vaults, and manage your files with complete controlβall on-chain, all transparent.
VaultHub combines the permanence of IPFS storage with the transparency of blockchain verification. Your files are yours aloneβnobody else can access or modify them unless you explicitly grant permission.
- π Complete Control β You own your data, nobody else
- π Blockchain Verified β Every action recorded on Ethereum
- π Permanent Storage β Files pinned to IPFS forever
- π― Granular Sharing β Share access per wallet address
- π¨ Zero Intermediaries β Decentralized, no servers, no backdoors
- Node.js 16+ and npm
- MetaMask or Web3-capable wallet
- Ethereum on Sepolia testnet (or local Hardhat network)
# Root (Hardhat + smart contracts)
npm install
# Frontend (React + Web3)
cd client && npm installCreate client/.env:
REACT_APP_PINATA_API_KEY=your_pinata_api_key
REACT_APP_PINATA_SECRET_KEY=your_pinata_secret_key
REACT_APP_CONTRACT_ADDRESS=0xYourDeployedContractAddressFor Sepolia Testnet:
npx hardhat run scripts/deploy-sepolia.js --network sepolia
# Copy the printed contract address into your .envFor local Hardhat node:
# Terminal 1: Start local blockchain
npx hardhat node
# Terminal 2: Deploy to localhost
npx hardhat run scripts/deploy.js --network localhostcd client && npm startThe app will open at http://localhost:3000
| Component | Technology |
|---|---|
| Blockchain | Ethereum (Sepolia / Hardhat) |
| Smart Contract | Solidity 0.8.9 |
| Storage | IPFS via Pinata |
| Frontend | React 18 + ethers.js v5 |
| Deployment | Vercel (auto-deploy on push) |
| Styling | CSS3 (Indigo/Black theme) |
- Drag & drop or click to upload
- Files automatically pinned to IPFS
- Upload recorded on-chain with one transaction
- Real-time transaction notifications
- View all your uploaded files
- Soft-delete files (marking as deleted in contract)
- Copy permanent IPFS links
- Manage file metadata on-chain
- Share Access β Grant wallet addresses permission to view your vault
- Revoke Access β Remove permission anytime
- Shared With section β See which addresses have access to your files
- Cross-Vault Viewing β View any vault you have permission for
- Transaction notifications (success/error/pending)
- Toast alerts for all actions
- Live blockchain verification status
- Auto-refresh of vault contents
VaultHub/
βββ contracts/
β βββ Upload.sol # Smart contract (ABI + logic)
βββ scripts/
β βββ deploy.js # Local deployment
β βββ deploy-sepolia.js # Sepolia testnet deployment
βββ hardhat.config.js
βββ client/
βββ public/ # Static assets
βββ src/
β βββ App.js # Main application shell
β βββ App.css # Theme & global styles (Indigo/Black)
β βββ index.css # CSS variables
β βββ components/
β βββ FileUpload.js # Upload zone component
β βββ FileUpload.css
β βββ Display.js # Vault contents viewer
β βββ Display.css
β βββ Modal.js # Share access modal
β βββ Modal.css
β βββ TransactionPanel.js # Real-time notifications
β βββ TransactionPanel.css
β βββ SharedWithMe.js # Shared addresses viewer
β βββ SharedWithMe.css
β βββ artifacts/ # Contract ABIs (auto-generated)
βββ package.json
Upload a file:
add(address _user, string url)Delete a file:
remove(uint256 index) // Marks file as deleted (soft-delete)View your vault:
display(address _user) -> string[] // Returns active files onlyGrant access:
allow(address user)Revoke access:
disallow(address user)See who has access:
shareAccess() -> Access[] // Returns access liststruct UploadedFile {
string url; // IPFS hash
bool deleted; // Soft deletion flag
}
struct Access {
address user; // Wallet address
bool access; // Permission status
}- Color Scheme: Pure black backgrounds (#0a0a0a), Indigo primary (#6366f1), Purple accents (#a78bfa)
- Animations: Smooth transitions, glowing effects, slide-in notifications
- Responsive: Works on desktop, tablet, mobile
- Glass Morphism: Frosted glass effect on cards and modals
- Dark Mode: Built-in, optimized for web3 interfaces
- Top navigation bar with wallet connection
- Upload zone with drag-and-drop support
- Vault contents grid with file management
- Share access modal with Ethereum address input
- Transaction notification panel
- Shared vaults viewer
- Footer with project info
- Connect GitHub repo to Vercel
- Set environment variables in Vercel settings:
REACT_APP_PINATA_API_KEYREACT_APP_PINATA_SECRET_KEYREACT_APP_CONTRACT_ADDRESS
- Push to
masterbranch β auto-deploys - Access your live app via Vercel URL
cd client
npm run build
# Build output in client/build/For development (client/.env):
REACT_APP_PINATA_API_KEY=pk_test_xxxxx
REACT_APP_PINATA_SECRET_KEY=sk_test_xxxxx
REACT_APP_CONTRACT_ADDRESS=0x1234567890123456789012345678901234567890# Terminal 1: Hardhat local blockchain
npx hardhat node
# Terminal 2: Deploy contract locally
npx hardhat run scripts/deploy.js --network localhost
# Terminal 3: React dev server
cd client && npm start- Open MetaMask
- Settings β Networks β Add Network
- Network Name:
Hardhat - RPC URL:
http://127.0.0.1:8545 - Chain ID:
31337 - Currency:
ETH
Sepolia Testnet:
- See your latest deployment output or check Vercel environment variables
Local Hardhat:
- Printed in terminal after running
deploy.js
- Private keys: Never commit
.envfiles with real keys - File hashes: IPFS links are permanentβverify before sharing
- Wallet security: Only grant access to trusted addresses
- Gas costs: Test on testnet before mainnet deployment
MIT License β Feel free to fork, modify, and build!
Found a bug? Have a feature idea? Open an issue or submit a PR!
VaultHub β Your files. Your rules. Forever. π