A production-ready web application that generates professional student ID cards from universities worldwide using AI-powered data generation.
- ๐ธ Custom Photo Upload with Base64 conversion (CORS-safe)
- ๐ด Dual Layout Support - Vertical and Horizontal ID card formats
- ๐ฅ Multiple Export Options - Download as PNG or PDF
- ๐ฑ Fully Responsive - Works on desktop, tablet, and mobile
- ๐ Zero Backend - Pure frontend, ready for GitHub Pages
Visit: https://thanhnguyxn.github.io/student-card-generator/
Warning
Legal Disclaimer - Read Carefully
This application is designed for educational and demonstration purposes only.
- โ NOT Official Documents: Generated student IDs are NOT valid official documents
- โ NO Legal Use: Do not use for identity verification, access control, or any legal purposes
- โ NO Impersonation: Do not use to impersonate students or gain unauthorized access
- โ NO Fraud: Misuse of this tool for fraudulent activities is illegal and punishable by law
Privacy & Data:
- All data is generated randomly using Faker.js - no real student information is used
- Uploaded photos are processed locally in your browser (Base64 conversion)
- No data is sent to any server or stored anywhere
- University logos and names are used for demonstration only - all trademarks belong to their respective owners
Intended Use:
- โ Learning web development techniques
- โ Portfolio demonstration
- โ UI/UX design reference
- โ Testing export/print functionality
By using this application, you agree to:
- Use it responsibly and ethically
- Not attempt to pass generated IDs as real documents
- Respect university trademarks and intellectual property
- Comply with all local laws and regulations
The author (@ThanhNguyxn) is NOT responsible for any misuse of this application.
| Technology | Version | Purpose |
|---|---|---|
| Tailwind CSS | 3.4 | Utility-first CSS framework |
| Faker.js | 5.5.3 | AI data generation with localization |
| html2canvas | 1.4.1 | Convert DOM to image |
| jsPDF | 2.5.1 | PDF generation |
| Google Fonts | Latest | Inter, Libre Baskerville, Great Vibes |
student-card-generator/
โ
โโโ index.html # Main entry point
โโโ css/
โ โโโ style.css # Custom glassmorphism & card styles
โโโ js/
โ โโโ universities.js # Database of 50+ universities (Real data)
โ โโโ script.js # Main application logic
โโโ README.md # This file
โโโ LICENSE # MIT License
-
Clone the repository
git clone https://github.com/ThanhNguyxn/student-card-generator.git cd student-card-generator -
Open in browser
# Just open index.html in your browser # No build process needed!
-
Or use a local server (recommended)
# Using Python python -m http.server 8000 # Using Node.js npx serve
-
Visit
http://localhost:8000
- Go to your repository on GitHub
- Click Settings โ Pages
- Under Source, select
mainbranch - Click Save
- Your site will be live at
https://YOUR_USERNAME.github.io/student-card-generator/
# Initialize git (if not already done)
git init
git add .
git commit -m "Initial commit: Global Student ID Generator"
# Connect to GitHub repository
git branch -M main
git remote add origin https://github.com/ThanhNguyxn/student-card-generator.git
git push -u origin main
# Enable GitHub Pages
# Go to Settings โ Pages โ Select 'main' branch โ Save# Create a gh-pages branch
git checkout -b gh-pages
git push origin gh-pages
# Go to Settings โ Pages โ Select 'gh-pages' branch โ Save- Select Country - Choose from 13 available countries
- Select University - Pick from top universities in that country
- Customize Details - Edit name, ID, major, or dates if needed
- Upload Photo (Optional) - Use your own photo or let AI generate one
- Generate Identity - Click "Generate New Identity" to refresh data
- Download - Export as PNG or PDF
- Hanoi University of Science and Technology (HUST)
- VNU University of Engineering and Technology (VNU-UET)
- VNU University of Information Technology (VNU-UIT)
- FPT University
- Posts and Telecommunications Institute of Technology (PTIT)
- VNU University of Science (HCMUS)
- Massachusetts Institute of Technology (MIT)
- Stanford University
- Harvard University
- UC Berkeley
- Yale University
- University of Oxford
- University of Cambridge
- Imperial College London
- The University of Tokyo
- Kyoto University
- Technical University of Munich (TUM)
- Ludwig Maximilian University of Munich (LMU)
- Context-Aware Localization: Vietnamese names for Vietnamese unis, Japanese for Japanese unis, etc.
- Intelligent Date Logic: Issue date randomly set 1-6 months in the past, valid for 4 years
- Realistic Emails: Generated based on university domain
- Unique IDs: Year + 5-digit random number
- Automatic Fallback: Random avatar from
pravatar.ccif no photo is provided - Secure Local Processing: Upload your own photo (automatically converted to Base64 for CORS safety)
- Crystal Clear PNG: High-quality image export using html2canvas
- Print-Ready PDF: Centered on A4 landscape page using jsPDF
Edit js/universities.js:
"YourCountry": [
{
name: "University Full Name",
shortName: "ABBR",
domain: "university.edu",
logo: "https://example.com/logo.png",
color: "#HEX_COLOR",
layout: "vertical", // or "horizontal"
address: "Full Address"
}
]Edit css/style.css:
- Modify
.id-cardfor overall card styling - Adjust
.glass-overlayfor glassmorphism effects - Update color schemes in
.card-header
Solution: Check browser console for errors. Ensure universities.js is loaded before script.js
Solution: Make sure you're using image files (JPEG, PNG, etc.). The app converts to Base64 automatically.
Solution: Ensure html2canvas and jsPDF are loaded from CDN. Check network tab for 404 errors.
Solution: Verify Faker.js version is 5.5.3 (not v6+). The new API syntax is different.
MIT License - feel free to use this project for personal or commercial purposes.
ThanhNguyxn
- GitHub: @ThanhNguyxn
- Project: student-card-generator
- University logos from Wikipedia Commons
- Faker.js for data generation
- html2canvas for DOM rendering
- jsPDF for PDF export
- QR code with real student data
- More countries and universities
- Custom color themes
- Batch generation
- Print-ready templates
Made with โค๏ธ by ThanhNguyxn
If you find this project useful, please give it a โญ on GitHub!
