A crowdsourced web platform where citizens report illegal landfills with photos + GPS coordinates, helping authorities and communities clean up the environment.
| Public map | Photo-first /report | Authority Dashboard |
|---|---|---|
![]() |
![]() |
![]() |
Illegal trash dumps pollute our forests, rivers, and neighborhoods. HackTheTrash lets anyone snap a photo, share their GPS location, and create a public, verifiable map of trash hotspots β so cities, NGOs, and volunteers can clean them up.
- πΈ Submit reports β photo upload + GPS auto-detection
- πΊοΈ Interactive map β public, color-coded by status
- π·οΈ Tags & severity β categorize trash (plastic, e-waste, hazardousβ¦)
- β Moderation system β verify reports, merge duplicates
- ποΈ Authority dashboard β track and resolve cleanups
- π Gamification β badges for active reporters
- π Privacy first β anonymous reporting, EXIF stripping
| Layer | Tech |
|---|---|
| Frontend (web) | Next.js 14 + TypeScript + TailwindCSS + Leaflet |
| Mobile app | React Native + Expo + Leaflet (WebView) |
| Backend | Node.js + Express + TypeScript |
| Database | PostgreSQL + PostGIS |
| Storage | AWS S3 / Cloudinary |
| Auth | JWT |
| Hosting | Vercel + Railway + EAS Build |
hackthetrash/
βββ frontend/ # Next.js app
β βββ src/
β β βββ app/ # Routes (report, map, dashboard, auth)
β β βββ components/
β β βββ lib/
β β βββ styles/
β βββ public/
βββ backend/ # Express API
β βββ src/
β β βββ routes/
β β βββ controllers/
β β βββ models/
β β βββ ai/ # Pluggable image classifier
β β βββ db/ # Migrations + seeds (PostGIS)
β β βββ middleware/
β β βββ services/
β βββ uploads/
βββ mobile/ # React Native (Expo) app
β βββ App.tsx
β βββ src/screens/ # Home, Report (camera+GPS), Map (OSM), Success
β βββ src/lib/
βββ docs/ # Wireframes, mockups, architecture, API docs
βββ scripts/ # Dev / deployment scripts
- Node.js 18+
- PostgreSQL 14+ (with PostGIS extension)
- npm or pnpm
git clone https://github.com/yourusername/hackthetrash.git
cd hackthetrashOption A β Docker Compose (everything, including Postgres+PostGIS):
docker compose up --build
# Web: http://localhost:3000
# API: http://localhost:4000
# DB: postgres://htt:htt@localhost:5432/hackthetrashOption B β Local Node (no Docker):
# Cross-platform (macOS / Linux / Windows):
node scripts/setup.mjs # install backend + frontend deps
node scripts/dev.mjs # start both services with prefixed logs
# Or platform-specific helpers:
bash scripts/setup.sh && bash scripts/dev.sh # bash
pwsh scripts/setup.ps1; pwsh scripts/dev.ps1 # PowerShellCopy .env.example to .env in both frontend/ and backend/:
# backend/.env
DATABASE_URL=postgresql://user:pass@localhost:5432/hackthetrash
JWT_SECRET=your_secret_here
PORT=4000
S3_BUCKET=...# frontend/.env.local
NEXT_PUBLIC_API_URL=http://localhost:4000
NEXT_PUBLIC_MAPBOX_TOKEN=...- Project scaffold
- MVP submission form + map
- Moderation panel
- Authority dashboard
- PostgreSQL + PostGIS schema & migrations
- AI image verification (pluggable, HuggingFace ready)
- HTML mockups
- Mobile app (Expo)
- Push notifications + offline queue
- i18n English + Albanian (Pristina-focused)
See docs/ROADMAP.md for full details.
- Architecture
- API Reference
- Database Setup
- AI Classification
- Mobile App
- Admin Panel
- Wireframes
- HTML Mockups
Contributions welcome! Please read CONTRIBUTING.md.
MIT Β© 2026 HackTheTrash Contributors
Built for a cleaner planet π±
Powered by FLOSSK


