Inspiration

Phishing attacks remain one of the biggest cybersecurity threats, causing millions of users to lose sensitive information through fake websites. Many phishing websites closely resemble legitimate ones, making them difficult to identify manually. We wanted to build an AI-powered solution that helps users quickly determine whether a URL is safe before visiting it, improving online security through machine learning.

What it does

The AI-Based Phishing URL Detection System analyzes a submitted URL and predicts whether it is legitimate or phishing. It extracts multiple security-related features from the URL, domain information, and webpage behavior, processes them through a trained machine learning model, and returns a prediction along with a confidence score. The application provides an easy-to-use web interface where users can instantly verify suspicious links.

How I built it

The project was built using Python, Flask, PyCaret, Pandas, HTTPX, and WHOIS.

The workflow includes:

  • Extracting URL-based features such as URL length, depth, suspicious keywords, IP addresses, and shortened URLs.
  • Gathering domain information using WHOIS, including domain age and expiration details.
  • Inspecting webpage behavior, including iframe usage, redirects, and JavaScript-based indicators.
  • Applying Principal Component Analysis (PCA) to optimize extracted HTML features.
  • Using a trained machine learning classification model built with PyCaret to classify URLs as phishing or legitimate.
  • Displaying the prediction and confidence score through a Flask-based web application.

Challenges I ran into

One of the biggest challenges was obtaining reliable domain information because WHOIS records are not always available or consistent across different registrars. Handling inaccessible websites, redirects, and missing HTML data without breaking the prediction pipeline also required extensive exception handling.

Another challenge was integrating multiple technologies—including feature extraction, PCA transformation, machine learning inference, and the Flask web application—into a seamless workflow while maintaining fast prediction times.

Accomplishments that I'm proud of

  • Successfully built an end-to-end phishing detection system using machine learning.
  • Developed a complete feature extraction pipeline combining URL, domain, and webpage characteristics.
  • Integrated the trained AI model into a responsive Flask web application.
  • Created a practical cybersecurity tool capable of providing real-time phishing predictions.
  • Improved my understanding of both cybersecurity concepts and machine learning deployment.

What I learned

This project taught me the importance of feature engineering in cybersecurity applications. I gained hands-on experience with machine learning model deployment, web application development, PCA-based feature reduction, WHOIS lookups, HTTP request handling, and Flask integration.

More importantly, I learned how combining traditional cybersecurity techniques with AI can produce practical tools that help users stay safe online.

What's next for AI-Based Phishing URL Detection System

We plan to expand the project by:

  • Integrating real-time threat intelligence services such as Google Safe Browsing and VirusTotal.
  • Improving model accuracy using larger and more up-to-date phishing datasets.
  • Adding explainable AI features to show why a URL is classified as phishing.
  • Developing a browser extension for instant URL scanning.
  • Providing detailed security reports and risk scores for analyzed websites.
  • Deploying the application to the cloud for public access and scalability.

Built With

Share this project:

Updates