Skip to content
Query Feedz
  • News
  • Business
    • Digital Marketing
      • Marketing & Sales
      • SEO
      • Content Marketing
      • AEO and GEO
    • Startups
      • Founder Stories
      • Funding & VC
      • Product & Growth
    • Money
      • Investing
      • Markets & Economy
      • Saving & Budgeting
  • AI & Technology
    • Technology
      • Consumer Tech
      • CRM
      • Cyber Security
      • Software Engineering
      • WordPress
      • Hardware
    • Artificial IntelligenceAI Glossary
      • LLMs
      • Machine Learning
      • AI Fundamentals
      • Generative AI
      • Deep Learning
    • AI Use Cases
      • Automation
      • Content
      • Customer Support
      • Finance
      • Marketing
      • View All
  • Tools & Software
  • Account
    • Submit Guest Post
    • Submit a tool
    • My listing
  • Contact
QueryFeedz
  • News
  • Business
    • Digital Marketing
      • Marketing & Sales
      • SEO
      • Content Marketing
      • AEO and GEO
    • Startups
      • Founder Stories
      • Funding & VC
      • Product & Growth
    • Money
      • Investing
      • Markets & Economy
      • Saving & Budgeting
  • AI & Technology
    • Technology
      • Consumer Tech
      • CRM
      • Cyber Security
      • Software Engineering
      • WordPress
      • Hardware
    • Artificial IntelligenceAI Glossary
      • LLMs
      • Machine Learning
      • AI Fundamentals
      • Generative AI
      • Deep Learning
    • AI Use Cases
      • Automation
      • Content
      • Customer Support
      • Finance
      • Marketing
      • View All
  • Tools & Software
  • Account
    • Submit Guest Post
    • Submit a tool
    • My listing
  • Contact
QueryFeedz
  1. Home /
  2. AI Glossaries /
  3. Machine Learning /
  4. What is Classification in Machine Learning?
Machine Learning

What is Classification in Machine Learning?

Updated September 20, 2026 Read 3 min

Classification in machine learning is a supervised learning task where a model learns to assign inputs to predefined categories, such as spam or not spam, by learning decision boundaries from labelled examples.

Contents 10
  1. 01Key takeaways
  2. 02How does a classifier learn?
  3. 03Types of classification
  4. 04Common algorithms and when to use them
  5. 05Evaluation metrics
  6. 06Choosing a threshold
  7. 07Limitations
  8. 08Common Use Cases
  9. 09Frequently Asked Questions
  10. 10Related Terms

Classification in machine learning is a supervised learning task in which a model learns to assign each input to one of several predefined categories, called classes. The model studies labelled examples, learns a decision boundary that separates the classes, and then predicts the class of new inputs, usually with a probability for each class.

This page covers the technical side: how classifiers learn, which algorithms and metrics to use and how thresholds work. For a plain-English overview of business uses, see What is AI Classification?

Key takeaways

  • Classification is one of the two core supervised learning tasks, alongside regression.
  • Classifiers usually output probabilities; a threshold turns them into class decisions.
  • Cross-entropy is the most common training loss.
  • Precision, recall, F1 and ROC-AUC are more informative than accuracy on imbalanced data.

How does a classifier learn?

Picture customers plotted on a chart by age and monthly spend, coloured by whether they churned. A classifier tries to draw a line, or a more complex shape, that separates the colours. That line is the decision boundary. Simple models draw straight boundaries; flexible models draw curved ones. Too simple and the model underfits. Too flexible and it overfits, tracing around individual points.

During training, the model predicts a probability for each class. Cross-entropy loss measures how far those probabilities are from the true labels, heavily penalising confident wrong answers. An optimiser such as gradient descent adjusts the model to reduce the loss.

Types of classification

TypeSetupOutput layer / approach
BinaryTwo classesOne probability, often via a sigmoid function
Multi-classOne of three or more classesProbabilities across all classes via softmax
Multi-labelSeveral classes at onceIndependent probability per label
ImbalancedOne class is rareClass weights, resampling, threshold tuning

Common algorithms and when to use them

AlgorithmStrengthsBest for
Logistic regressionFast, explainable, good baselineRegulated or simple problems
Decision treeEasy to visualiseExplaining rules to stakeholders
Random forestRobust, little tuningGeneral tabular data
Gradient boosting (XGBoost, LightGBM, CatBoost)Often top accuracy on tablesFraud, credit, churn
Support vector machineStrong on smaller, high-dimensional dataText features, small datasets
k-nearest neighboursSimple, no training phaseSmall datasets, baselines
Neural networksLearn complex patternsImages, audio, text

Evaluation metrics

  • Confusion matrix: counts true positives, false positives, true negatives and false negatives.
  • Precision = TP / (TP + FP): how trustworthy positive predictions are.
  • Recall = TP / (TP + FN): how many real positives were caught.
  • F1 score: the harmonic mean of precision and recall.
  • ROC-AUC: how well the model ranks positives above negatives across all thresholds.
  • PR-AUC: more informative than ROC-AUC when positives are rare.
  • Log loss: rewards well-calibrated probabilities.

Choosing a threshold

Most classifiers predict “positive” when the probability is above 0.5 by default. That is rarely optimal. Lowering the threshold catches more positives (higher recall) but raises false alarms (lower precision). Pick the threshold using the validation set and the real cost of each error type.

Limitations

Classifiers depend on label quality and can only predict classes they have seen. Imbalanced data can hide poor performance behind high accuracy. Probabilities may be poorly calibrated. And models can pick up spurious shortcuts, such as a watermark that happens to appear in one class of images.

Common Use Cases

01

Fraud detection

Binary classifiers flag suspicious payments, tuned for the right precision-recall balance.

02

Churn prediction

Classify customers as likely to leave or stay to target retention offers.

03

Image classification

Neural networks label product photos, defects or medical images.

04

Text categorisation

Route support tickets or tag articles by topic.

05

Lead scoring

Classify leads as likely or unlikely to convert based on past deals.

06

Intent detection

Classify user messages in chatbots to trigger the right response.

Frequently Asked Questions

A supervised learning task where a model predicts which predefined category an input belongs to, based on labelled training examples.

The line or surface a classifier learns to separate one class from another in the feature space.

Cross-entropy, also called log loss, is the most common loss for training classifiers.

There is no single best. Gradient boosting often leads on tabular data, and neural networks lead on images and text. Always start with a simple baseline.

Because the cost of false positives and false negatives usually differs. The best threshold depends on the business trade-off.

Related Terms

  • AI Classification
  • Regression
  • Supervised Learning
  • Loss Function
  • Precision and Recall
  • Decision Boundary

Related AI Terms

What is Hyperparameter Tuning?Hyperparameter tuning is the process of systematically searching for the configuration values that make a model perform best…What is L2 Regularization?L2 regularization adds a penalty equal to the sum of the squared weights, shrinking all weights smoothly towards…What is L1 Regularization?L1 regularization, known as lasso in linear models, adds a penalty equal to the sum of the absolute…What is Cross-Validation in Machine Learning?Cross-validation is a technique that repeatedly splits data into training and validation parts, rotating which part is held…What is Stochastic Gradient Descent (SGD)?Stochastic gradient descent (SGD) updates a model's weights using one example or a small batch at a time…What is the Bias-Variance Tradeoff?The bias-variance tradeoff describes how a model's error splits into bias from overly simple assumptions and variance from…

Contents

  1. 01Key takeaways
  2. 02How does a classifier learn?
  3. 03Types of classification
  4. 04Common algorithms and when to use them
  5. 05Evaluation metrics
  6. 06Choosing a threshold
  7. 07Limitations
  8. 08Common Use Cases
  9. 09Frequently Asked Questions
  10. 10Related Terms

AI Topic

  • Machine Learning

Related Terms

  • What is Hyperparameter Tuning?
  • What is L2 Regularization?
  • What is L1 Regularization?
  • What is Cross-Validation in Machine Learning?
  • What is Stochastic Gradient Descent (SGD)?
  • What is the Bias-Variance Tradeoff?

Quick Navigation

  • Common Use Cases
  • Frequently Asked Questions
  • Related Terms
  • Back to top

Details

Updated
September 20, 2026
Read
3 min
  • Forum
  • Submit a tool
  • Submit Guest Post
  • List Your Startup
  • Privacy Policy
  • Editorial Policy
  • Account
  • Contact
  • AI Productivity
  • AI Video
  • AI Coding
  • AI Chatbots
  • Sales
  • AI Business
  • View All Tools

Subscribe our Newsletter

Get weekly exclusive content - No spam.

Copyright © 2026 -  Query Feedz

Manage Consent
To provide the best experiences, we use technologies like cookies to store and/or access device information. Consenting to these technologies will allow us to process data such as browsing behavior or unique IDs on this site. Not consenting or withdrawing consent, may adversely affect certain features and functions.
Functional Always active
The technical storage or access is strictly necessary for the legitimate purpose of enabling the use of a specific service explicitly requested by the subscriber or user, or for the sole purpose of carrying out the transmission of a communication over an electronic communications network.
Preferences
The technical storage or access is necessary for the legitimate purpose of storing preferences that are not requested by the subscriber or user.
Statistics
The technical storage or access that is used exclusively for statistical purposes. The technical storage or access that is used exclusively for anonymous statistical purposes. Without a subpoena, voluntary compliance on the part of your Internet Service Provider, or additional records from a third party, information stored or retrieved for this purpose alone cannot usually be used to identify you.
Marketing
The technical storage or access is required to create user profiles to send advertising, or to track the user on a website or across several websites for similar marketing purposes.
  • Manage options
  • Manage services
  • Manage {vendor_count} vendors
  • Read more about these purposes
View preferences
  • {title}
  • {title}
  • {title}