A blockchain-based decentralized voting system built using React, Solidity, and Web3.js to ensure secure and transparent elections.
β
Secure Voting: Uses blockchain to prevent tampering.
β
Decentralized: No central authority controls the votes.
β
Real-time Verification: Admin can verify registered voters.
β
Transparent Results: Anyone can verify the election outcome.
β
User-Friendly Interface: Simple UI for voters and admins.
Voting_System/
βββ public/ # Static assets
βββ src/ # Main source code
β βββ components/ # Reusable UI components
β βββ contracts/ # Solidity smart contracts
β βββ pages/ # Main pages (Registration, Voting, Verification)
β βββ utils/ # Helper functions & Web3 setup
βββ .gitignore
βββ package.json
βββ README.md
βββ truffle-config.js # Truffle configuration for deploying smart contracts
- Frontend: React, CSS
- Backend: Solidity (Ethereum Smart Contracts)
- Blockchain Integration: Web3.js
- Development Framework: Truffle
git clone https://github.com/yourusername/Voting_System.git
cd Voting_System
npm install
- Download & install Ganache.
- Open Ganache and start a new workspace.
truffle compile
truffle migrate --network development
npm start
Function | Description |
---|---|
registerVoter(address, name, phone) |
Registers a new voter |
getTotalVoter() |
Returns the total number of voters |
verifyVoter(address) |
Admin verifies a voter |
vote(candidateId) |
Voter casts their vote |
getResults() |
Fetches election results |
πΉ Add biometric authentication for voter verification.
πΉ Improve UI/UX with animations and better accessibility.
πΉ Deploy on Ethereum Mainnet instead of local blockchain.
This project is open-source under the MIT License.