PhishGuard is a lightweight FastAPI-based API that detects phishing attempts using both URL structure and email content, powered by a trained machine learning model.
- 🔍 Detect phishing using:
- URL features (length, digits, suspicious keywords, etc.)
- Natural Language Processing (TF-IDF) on email content
- ⚙️ FastAPI backend
- 🤖 Trained RandomForest model (41 input features)
- 🌐 Public API endpoint (deployed via Render)
🧾 Input (JSON):
{
"url": "http://secure-login-paypal.com",
"email_text": "URGENT! Your account is locked! Click here to unlock."
}📤 Output (JSON):
{
"label": "phishing",
"confidence": 0.78
}Use the following hosted links to explore and test PhishGuard in real-time:
-
📘 Swagger UI (Test API in browser)
https://phishguard-api-89n2.onrender.com/docs -
⚙️ Base API Endpoint (for POST requests only)
https://phishguard-api-89n2.onrender.com/predict
Note: This URL only accepts POST requests. It will return an error if opened directly in the browser.
- 🔗 GitHub Repo:
https://github.com/tanimrahman10/phishguard-api
Feel free to ⭐️ star the project or fork it!
Use this sample JSON to test phishing detection:
{
"url": "http://secure-login-paypal.com",
"email_text": "URGENT! Your account is locked! Click to unlock now."
}