| .github/workflows | ||
| frontend | ||
| worker | ||
| .gitignore | ||
| LICENSE | ||
| package.json | ||
| pnpm-lock.yaml | ||
| pnpm-workspace.yaml | ||
| README.en.md | ||
| README.md | ||
| wrangler.toml | ||
🚀 ZMAIL - 24-hour Temporary Email Service
English | 中文
If you find this project helpful, please consider giving it a ⭐️ Star ⭐️. Your support is greatly appreciated!
💌 Secure, Simple, Disposable Email Service
🌐 Live Demo • ✨ Features • 🚀 Deployment • 💻 Development • 🔧 Tech Stack
✨ Features
✨ Instant Creation
Get a temporary email address instantly, no registration required
🔒 Privacy Protection
Protect your real email from spam and data leaks
⚡ Real-time Reception
Receive emails in real-time without refreshing the page
🌐 Global Availability
Built on Cloudflare's global edge network for fast access worldwide
🔄 Auto-refresh
Automatically check for new emails, never miss important messages
📱 Responsive Design
Perfect fit for all devices, from mobile to desktop
🚀 Quick Deployment
ZMAIL now adopts a brand new integrated deployment approach, with frontend and backend integrated into a single Cloudflare Worker, making deployment even simpler!
🎯 Deployment Options
We provide two deployment methods, you can choose according to your needs:
Option 1: One-Click Deployment (Recommended for Beginners)
✅ Advantages:
- Simple deployment, one-click completion
- No need to modify configuration files
- Perfect for quick testing
❌ Disadvantages:
- Cannot receive subsequent code updates
- Need to manually bind custom domain
📋 Deployment Steps:
- Click the "Deploy to Cloudflare" button above
- Follow the page instructions to connect your GitHub account
- Fill in application name and database name
- In Advanced Settings -> Build Variables, set:
VITE_EMAIL_DOMAIN: Your domain list, separated by ',' (e.g., mdzz.uk,zaunist.com)
- Click "Create and Deploy"
- After deployment, bind custom domain in Cloudflare Workers dashboard
- Configure Cloudflare Email routing to forward emails to your Worker
Option 2: Fork and Custom Deployment via Github Action (Recommended for Advanced Users)
✅ Advantages:
- Can receive subsequent code updates
- Fully customizable configuration
- Better version control
- Automatic deployment via GitHub Actions, more secure and convenient
❌ Disadvantages:
- Requires some technical knowledge
- Need to manually create database and configure secrets
📋 Deployment Steps:
- Fork this project to your GitHub account
- Create a D1 database in your Cloudflare Dashboard and note down the database_name and database_id
- In your GitHub repository, go to Settings > Secrets and variables > Actions
- Click New repository secret and add the following five secrets:
CF_API_TOKEN: Your Cloudflare API Token. You can create one here using the "Edit Cloudflare Workers" template.CF_ACCOUNT_ID: Your Cloudflare Account ID. You can find it on the right side of the Workers page.D1_DATABASE_ID: The ID of the D1 database you created in step 2.D1_DATABASE_NAME: The name of the D1 database you created in step 2.VITE_EMAIL_DOMAIN: Your list of domains, separated by commas (e.g., example.com,test.com).
- After completing the steps above, the project will be automatically deployed on every push to the
mainbranch. You can also trigger the deployment manually from the Actions page. - After deployment, bind a custom domain to your Worker.
- Finally, configure Cloudflare Email Routing to forward emails to your Worker.
📧 Configure Email Routing
Regardless of which deployment method you choose, you need to configure Cloudflare Email routing:
- Find your domain in the Cloudflare dashboard
- Go to "Email" -> "Email Routing"
- Enable Email Routing
- Add routing rules:
- Match type: "Catch-all address"
- Action: "Send to a Worker"
- Select your deployed Worker
- If you have multiple domains, repeat the above steps for each domain
💻 Local Development
🚀 Development
# install dependencies
pnpm install
# start frontend development server
pnpm dev:frontend
# start backend development server
pnpm dev:backend
⚙️ Deployment
# deploy
pnpm run deploy
🔧 Tech Stack
🎨 Frontend
- React - UI library
- TypeScript - Type-safe JavaScript
- Tailwind CSS - Utility-first CSS framework
- Vite - Modern frontend build tool
⚙️ Backend
- Cloudflare Workers - Edge computing platform
- Cloudflare D1 - Edge SQL database
- Cloudflare Email Workers - Email processing service
👥 Contributing
Contributions via Pull Requests or Issues are welcome!