UCI Machine Learning Repository

Also known as: UCI repository

On this page 7

The UCI Machine Learning Repository is a public archive of curated datasets maintained by the University of California, Irvine, that researchers, teachers and practitioners use to train, test and compare machine learning algorithms. Within the study of training data in artificial intelligence, it is one of the oldest and most cited sources of benchmark datasets, best known for small tabular collections such as Iris, Adult and Wine.

Founded in 1987 as a shared FTP archive for the machine learning community, the UCI repository now hosts more than 600 datasets with standardized descriptions, variable metadata and citation details. Its value lies less in scale than in reproducibility: the same files, under the same names, have supported decades of comparable experiments.

How the UCI repository organizes and distributes datasets

The UCI Machine Learning Repository works as a catalog of donated datasets, each published with a landing page, downloadable files and a structured description. Contributors submit data together with documentation, and the maintainers check that the description, variable roles and licensing information are complete before publication.

Every entry carries a consistent set of metadata fields. The most important ones tell a user what task the data supports, how many rows and columns it contains, and whether values are missing. The table below summarizes the core fields and why they matter in practice.

FieldWhat it recordsWhy it matters
Task typeClassification, regression, clustering or otherNarrows the search to suitable problems
InstancesNumber of rows or examplesIndicates statistical power and training cost
FeaturesNumber and type of attributesShows dimensionality and preprocessing needs
Missing valuesWhether gaps exist and how they are codedPrevents silent errors during loading
Variable rolesTarget, feature or identifier for each columnAvoids using an ID or label as an input
License and DOIUsage terms and a persistent identifierEnables legal reuse and exact citation
Core metadata fields on a dataset page

Since the site redesign in 2023, datasets can be loaded directly in Python with the ucimlrepo package, where a call such as fetch_ucirepo(id=53) returns the features, targets and metadata as data frames. Most recent datasets are released under the Creative Commons Attribution 4.0 license and receive a digital object identifier for citation.

Well-known datasets in the UCI collection

A handful of UCI datasets have become standard teaching and benchmarking material because they are small, clean enough to use quickly and well documented. Many appear in textbooks, library tutorials and introductory courses as the first example of a supervised learning task.

DatasetInstancesFeaturesTypical task
Iris1504 numericThree-class flower classification
Adult (Census Income)48,84214 mixedPredicting income above 50,000 USD
Wine17813 numericThree-class cultivar classification
Breast Cancer Wisconsin (Diagnostic)56930 numericBenign versus malignant tumors
Mushroom8,12422 categoricalEdible versus poisonous classification
Wine Quality6,49711 numericQuality score regression or classification
Bank Marketing45,21116 mixedPredicting term deposit subscription
Frequently used UCI datasets and their typical tasks

These datasets are deliberately modest in size. A model trains on Iris in milliseconds, which makes it ideal for demonstrating algorithms, but the same property means that accuracy differences on Iris rarely say anything about performance on real production data.

How the UCI repository compares with other dataset sources

The UCI repository occupies a distinct niche among public data sources: it specializes in small and medium tabular datasets with careful documentation, whereas newer collections focus on images, text or web-scale corpora. Choosing a source therefore depends on the modality and scale of the problem.

SourceMain data typeTypical scalePrimary use
UCI repositoryTabular, some time series and textHundreds to millions of rowsAlgorithm comparison and teaching
OpenMLTabular with linked experimentsSimilar to UCIReproducible benchmarking runs
ImageNetLabeled imagesAbout 14 million imagesComputer vision pretraining
Common CrawlRaw web pagesPetabytesLanguage model pretraining corpora
Kaggle datasetsMixed, community uploadedHighly variableCompetitions and exploration
UCI compared with other well-known dataset sources

Unlike community platforms where anyone can upload files, UCI applies editorial review to submissions. The trade-off is a smaller catalog in exchange for more consistent metadata, which is why many statistical learning papers still report results on UCI datasets.

Using UCI datasets responsibly in experiments

Good practice with UCI data starts with reading the dataset description before writing any code. Descriptions often explain how missing values are encoded, which columns leak the target, and whether the official split into training and test files should be preserved.

  • Use the original train-test split when one is published, so results remain comparable with earlier work.
  • Apply stratified cross-validation on small datasets, because a single split of 150 rows produces unstable estimates.
  • Check for duplicate rows, which inflate accuracy when copies land in both training and test folds.
  • Cite the dataset with its DOI and creators, as the license requires attribution.

Researchers who compare algorithms should report results across many datasets rather than one, together with variance across folds. A method that wins on a single UCI dataset by a fraction of a percent has usually demonstrated noise, not genuine superiority.

Limitations and known problems of UCI benchmarks

The age and popularity of the UCI repository create specific weaknesses that experienced practitioners account for. Several classic datasets were collected decades ago, under conditions that no longer reflect current populations, and some contain documented biases or errors.

IssueCauseMitigation
Benchmark overfittingDecades of tuning on the same filesEvaluate on fresh or held-out data
Dataset biasHistorical sampling, such as 1994 census dataAudit subgroup performance and fairness
Small sample sizeDatasets with only hundreds of rowsUse repeated cross-validation and intervals
Label noiseManual or legacy labeling errorsInspect suspicious examples before training
Outdated formatsPlain text files with ad hoc codesLoad through ucimlrepo or verified parsers
Common issues, their causes and mitigations

The Boston Housing dataset illustrates these risks. Once widely used for regression, it was removed from major libraries because one engineered feature encoded racial composition in a problematic way. The episode is a reminder that benchmark status does not guarantee suitability for modern use.

The idea in brief

The UCI Machine Learning Repository is a free public library of datasets. A university in California runs it. Researchers and students download data from it to teach computers to find patterns.

Think of it as a shared set of practice exams. Everyone can use the same questions. That makes it easy to compare results between different methods. The datasets are small and well described, so they suit learning and quick tests. They do not always reflect messy real-world data, so good results on them are only a first step.

A practical scenario

A data science instructor preparing a university course on classification needs a dataset that students can load in one line and train on a laptop. She chooses the Breast Cancer Wisconsin (Diagnostic) dataset from the UCI repository, with 569 instances and 30 numeric features, and loads it with ucimlrepo in the first lab session.

Students compare logistic regression, a decision tree and a support vector machine using 10-fold stratified cross-validation. Most models reach accuracy between 93 and 97 percent, and the class discusses why the differences fall within fold-to-fold variance. The instructor then asks each student to examine false negatives, since a missed malignant case costs far more than a false alarm.

The outcome is a course module in which students learn evaluation discipline, not just model fitting, and understand why results on a small benchmark must not be presented as clinical evidence.