UMAP and t-SNE both compress high-dimensional data into two-dimensional scatter plots that reveal clusters and patterns invisible in raw tables, but they differ in speed, how they handle global structure, and how sensitive they are to settings. UMAP is generally faster on large datasets and can embed new data points without rerunning the entire algorithm, while t-SNE tends to produce tighter, more visually separated clusters. Recent research, however, suggests these two methods are far more alike than their separate origin stories imply, with a single technical choice accounting for most of the visual differences between them.
Why These Methods Exist
Most real-world datasets have dozens, hundreds, or thousands of measured features per sample. A single-cell RNA sequencing experiment, for instance, can measure the activity of 20,000 or more genes in every cell. You cannot plot 20,000 dimensions on a screen, so you need a way to squash the data down to two or three dimensions while keeping the interesting structure intact. Older linear approaches assume the important patterns in data fall along straight lines in high-dimensional space. Biological systems and many other complex datasets violate that assumption, because relationships among features are often curved and tangled. When a linear method is forced onto nonlinear data, the resulting low-dimensional picture can miss the real structure entirely.1Elsevier (Biomedical Signal Processing and Control). Limitations of principal component analysis in COVID-19 CT image classification
t-SNE, introduced in 2008, and UMAP, introduced about a decade later, both belong to a newer class of nonlinear methods designed to handle exactly this kind of data. They work by building a model of which points are neighbors in the original high-dimensional space, then arranging points on a flat map so that those neighbor relationships are preserved as faithfully as possible. The details of how they define “neighbor” and how they punish mistakes in the map are where the two methods diverge.
How t-SNE Builds Its Map
t-SNE starts by measuring distances between every pair of points in the original space and converting those distances into probabilities. Two points that are close together get a high probability of being neighbors; two points that are far apart get a near-zero probability. In the original high-dimensional space, this conversion uses a bell-shaped Gaussian curve. In the low-dimensional map, however, t-SNE deliberately switches to a heavier-tailed distribution, specifically a Student t-distribution with one degree of freedom. The heavier tail means that points which are only moderately far apart in high dimensions can be pushed much further apart on the map without penalty.2Computo. Visualizing Data Using t-SNE (Mock Contribution) – Section: Mismatched tails can compensate for mismatched dimensionalities
The practical effect of that heavy tail is what gives t-SNE plots their characteristic look: tight, well-separated blobs. Because moderate distances in high dimensions get inflated on the map, clusters tend to pull apart from each other dramatically. The algorithm finds its map by starting from a random arrangement and iteratively nudging points around to minimize the mismatch between the high-dimensional probabilities and the low-dimensional ones. That mismatch is measured using a quantity called Kullback-Leibler divergence, and the optimization proceeds through gradient descent.3arXiv. Convergence analysis of t-SNE as a gradient flow for point cloud on a manifold A well-known concern is that this optimization can get stuck in poor arrangements, especially with default settings, producing maps that look reasonable but do not reflect the true structure of the data.4arXiv. Stochastic Neighbor Embedding under f-divergences
How UMAP Builds Its Map
UMAP approaches the same problem from a different theoretical angle, drawing on ideas from topology and geometry. Rather than converting distances into pairwise probabilities using a Gaussian, UMAP constructs a weighted graph connecting each point to its nearest neighbors, then tries to lay out that graph in two dimensions so the connections are preserved. The theoretical framework is rooted in Riemannian geometry and algebraic topology, which gives UMAP a more formal mathematical foundation than t-SNE’s probability-matching story.5arXiv. UMAP: Uniform Manifold Approximation and Projection for Dimension Reduction
In practice, though, the output looks a lot like t-SNE: a scatter plot with clusters. One key difference in the optimization is that UMAP uses a cross-entropy-style loss function rather than the strict Kullback-Leibler divergence t-SNE relies on. UMAP also uses a technique called negative sampling during optimization, where it does not consider all pairs of points at every step but instead samples a small number of “negative” non-neighbor pairs to push apart. This shortcut is a major reason UMAP runs faster. A recent theoretical analysis showed that UMAP’s optimization, when solved this way, is effectively equivalent to performing spectral clustering on its fuzzy nearest-neighbor graph.6arXiv. UMAP Is Spectral Clustering on the Fuzzy Nearest-Neighbor Graph – Section: 3.1 Proof of Theorem 3.1 That result reframes UMAP less as a topology-preserving embedding and more as a clustering method that happens to produce nice pictures.
They Are More Alike Than They Look
Despite the different origin stories, a striking finding from recent comparative work is that the visual differences between t-SNE and UMAP outputs trace mostly to a single parameter: whether the algorithm normalizes its similarity scores globally or locally. t-SNE normalizes across all pairs of points so that the pairwise probabilities sum to one, while UMAP normalizes locally, within each point’s neighborhood. When researchers controlled for that one choice and aligned the rest of the settings, the two methods produced nearly indistinguishable results.7arXiv. ActUp: Analyzing and Consolidating tSNE and UMAP
This matters because the community has spent years debating which algorithm is “better” at preserving structure, which is more faithful to the true data geometry, and which is more trustworthy for downstream analysis. If the main dial you are turning is just normalization scope, many of those debates are really about parameter defaults rather than fundamental algorithmic superiority. It does not mean the choice is irrelevant, since the default behavior of each method still leads to different-looking plots, and those defaults shape what most users actually see. But it does mean the gap between them is narrower than it appears.
Speed and Scalability
On datasets of a few thousand points, both methods finish in seconds to minutes, and the speed difference is negligible. As datasets grow into the hundreds of thousands or millions of points, UMAP pulls ahead. Its negative-sampling optimization avoids the all-pairs computation that the standard t-SNE algorithm requires, giving UMAP a meaningful speed advantage on large datasets. For very large-scale work, a GPU-accelerated implementation of UMAP is available in the open-source RAPIDS cuML library, which can cut runtimes dramatically by offloading the computation to graphics hardware.8Proceedings of the AAAI Conference on Artificial Intelligence. Bringing UMAP Closer to the Speed of Light with GPU Acceleration
That said, fast approximations of t-SNE, such as the Barnes-Hut and FIt-SNE implementations, have closed much of the gap. On a dataset of a million points, UMAP still tends to be faster, but the difference is less dramatic than it was when UMAP first appeared. For most practical purposes, if your dataset fits comfortably in memory and you are running a modern t-SNE implementation, both will finish in a reasonable time. UMAP’s edge becomes decisive mainly when you are iterating quickly on very large datasets or embedding data in a production pipeline where seconds matter.
Global Structure and the Initialization Trap
One of the most commonly repeated claims about UMAP is that it preserves global structure better than t-SNE, meaning the relative positions of clusters on the map reflect how different those clusters really are. If cluster A is biologically closer to cluster B than to cluster C, a method with good global-structure preservation should place A nearer to B on the plot. Early benchmarks seemed to confirm UMAP’s advantage here, and the claim became part of the standard pitch for choosing UMAP over t-SNE.
That claim, however, was complicated by a study showing that the apparent advantage was largely an artifact of how each algorithm was initialized. When both t-SNE and UMAP started from a random layout, neither preserved global structure well. When both started from an informative initialization, such as the first two principal components of the data, both preserved global structure comparably well. The takeaway was that initialization matters more than the choice of algorithm.9bioRxiv. UMAP does not preserve global structure any better than t-SNE when using the same initialization Modern implementations of both methods now default to informative initialization for exactly this reason, but if you are using an older version or a wrapper that resets to random starts, you may unknowingly sacrifice global structure regardless of which algorithm you choose.
Hyperparameter Sensitivity
Both methods have tunable settings that affect the output, and neither is truly “set it and forget it.” For t-SNE, the most discussed parameter is perplexity, which roughly controls how many neighbors each point considers when building its probability model. The default in most implementations is 30, but qualitatively different pictures can emerge at much higher values. A practical rule of thumb is to try a perplexity around one percent of your sample size: for a dataset of 15,000 points, that would be about 150. Higher perplexity pulls larger structures together at the expense of fine local detail, improving the global picture but potentially smearing small clusters.10Nature Communications. The art of using t-SNE for single-cell transcriptomics
Beyond perplexity, the learning rate and an early-exaggeration factor also shape t-SNE results. Systematic exploration across datasets found that good hyperparameter combinations tend to involve low exaggeration, and to a lesser extent low perplexity and low learning rate. Importantly, the “best” combination is somewhat dataset-dependent, with some parameter sets that perform poorly on average still producing accurate embeddings for specific datasets.11Visual Informatics. New guidance for using t-SNE: Alternative defaults, hyperparameter selection automation, and comparative evaluation
UMAP’s main knob is n_neighbors, which controls how many nearest neighbors define each point’s local neighborhood. Small values emphasize fine local detail; large values smooth things out and capture broader structure. In the presence of noise, the optimal n_neighbors can be surprisingly high. One study on single-cell RNA sequencing data found that a value of 190 maximized the faithfulness of the embedding compared to the original data, and pushing it to 300 maximized faithfulness when comparing against the underlying signal rather than the noisy measurements.12PLOS Computational Biology. Calibrating dimension reduction hyperparameters in the presence of noise Those values are far above the default of 15 in most UMAP implementations, which suggests that the defaults are tuned for clean, low-noise data and can underperform badly on messier real-world measurements.
Handling New Data
A practical limitation of standard t-SNE is that it has no built-in way to embed new points after the initial map is computed. If you get ten more samples tomorrow, you have to rerun the entire algorithm on the combined old-plus-new dataset. The new run can produce a layout that looks different from the previous one, making it hard to track changes over time or deploy the embedding in a live system.
UMAP has a modest advantage here: its standard implementation includes a transform method that projects new points onto an existing embedding using the learned graph structure. For more demanding applications, a parametric version of UMAP replaces the graph-based optimization with a neural network that learns a mapping function from the input space to the embedding. Once trained, that network can embed new data points instantly, without touching the original dataset. Benchmarks show that parametric UMAP performs comparably to the standard version in terms of embedding quality while enabling fast online embedding of new data.13PubMed Central. Parametric UMAP Embeddings for Representation and Semisupervised Learning This makes UMAP the more natural choice for production workflows where new data arrives continuously.
What the Plots Do Not Tell You
The most dangerous misuse of both methods is reading too much into the map. Neither t-SNE nor UMAP produces plots where the distance between clusters is meaningful. Two clusters that appear far apart on the map are not necessarily more different than two clusters sitting close together. The algorithms optimize for preserving local neighborhood relationships, and the gaps between clusters on the final plot are largely a byproduct of the optimization process, not a reliable measure of biological or statistical distance. Linear methods like PCA and classical multidimensional scaling do a better job of preserving between-cluster distances, which is why those older methods remain useful for tasks where the relative positioning of groups matters.14arXiv. Stop Misusing t-SNE and UMAP for Visual Analytics – Section: 3.3 Suitability of DR Techniques to Analytic Tasks
Cluster density is another trap. A tight, compact cluster on a t-SNE or UMAP plot does not necessarily mean those points are more tightly grouped in the original data. The algorithms can artificially compress or expand regions depending on local density and the interplay of attractive and repulsive forces during optimization. Specialized variants like densMAP and den-SNE have been developed to better represent density, but the standard versions do not. If your analysis depends on comparing how spread out different groups are, you need either a density-aware variant or a different method entirely.
A related pitfall is treating the number of visible clusters as ground truth. Both methods can split a single continuous population into what looks like several distinct blobs, or merge genuinely distinct groups into one amorphous cloud, depending on the hyperparameters. Changing the perplexity in t-SNE or n_neighbors in UMAP can make clusters appear or vanish. Any downstream clustering should be performed on the original high-dimensional data, not on the two-dimensional embedding.
Applications in Single-Cell Biology
The field where these methods have had the most impact is single-cell transcriptomics, where researchers profile gene expression in thousands to millions of individual cells. Both t-SNE and UMAP have become standard visualization tools in this domain, and each has strengths that suit different analytical goals. A comparative study using trajectory-aware metrics across multiple single-cell datasets found that UMAP consistently excelled at capturing continuous developmental transitions and branching structures in the data, while t-SNE showed stronger cluster separation, meaning it drew sharper boundaries between cell types.15Scientific Reports. A comparative study of manifold learning methods for scRNA-seq with a trajectory-aware metric
In practice, this means t-SNE is often preferred when the goal is to identify and label discrete cell types, because its tight clusters make group boundaries visually obvious. UMAP tends to be the better choice when the biological question involves continuous processes like cell differentiation, where cells transition gradually from one state to another rather than falling into neat categories. Many research groups now generate both plots and use them for complementary purposes rather than picking one and discarding the other.
Supervised Extensions
Both methods were originally designed for unsupervised exploration: you give them data, they give you a picture, and no labels are involved. UMAP, however, has a built-in option for supervised or semi-supervised embedding, where you can supply class labels and the algorithm will adjust the embedding to better separate those classes. This is useful when you already know the groupings and want a visualization that highlights the distinctions, or when you have partial labels and want the embedding to leverage what you know while still discovering new structure in the unlabeled portion.
A more sophisticated extension called DG-UMAP goes further by fitting a classifier in the original feature space first, then using the geometry of that classifier’s decision boundaries to reshape the data before embedding. Rather than directly forcing classes apart in the final picture, the supervision acts through the data geometry, producing embeddings that better agree with the class structure and the global organization of the data while still preserving local neighborhoods.16PubMed Central. Faithful Supervised Dimensionality Reduction for Biomedical Data via Decision Geometry These supervised variants are particularly relevant in biomedical settings where ground-truth labels exist from pathology or flow cytometry, and the goal is to project the data into a space that faithfully reflects both the known biology and whatever additional structure the data contains.
Newer Alternatives Worth Knowing About
The landscape of dimensionality reduction is not frozen at t-SNE and UMAP. A large-scale benchmark comparing multiple methods on transcriptomic data found that a newer technique called PaCMAP achieved a useful middle ground: it preserved local structure nearly as well as t-SNE and UMAP, handled global structure better than either, was more robust to parameter and preprocessing choices, and ran faster than both.17Communications Biology. Towards a comprehensive evaluation of dimension reduction methods for transcriptomic data visualization PaCMAP works by sampling three types of point pairs (near, mid-range, and far) and balancing attractive and repulsive forces across all three scales, which naturally captures more of the global geometry without requiring careful parameter tuning.
TriMap and ForceAtlas2 were also strong performers on global-structure metrics in the same benchmark. The broader trend is toward methods that try to preserve structure at multiple scales simultaneously rather than focusing almost exclusively on local neighborhoods the way t-SNE and UMAP do. For exploratory work where you want to understand both the fine-grained clusters and the large-scale landscape of your data, these newer methods deserve a serious look. That said, t-SNE and UMAP remain far more widely adopted, with larger ecosystems of tutorials, compatible tools, and community knowledge. Switching to a newer method means trading maturity for potential quality gains, and for many users, the familiar methods still perform well enough that the trade-off is not obviously worth it.
Picking One for Your Project
If your dataset has fewer than about 50,000 points, both methods will run fast enough that speed is not a deciding factor. Choose t-SNE when your primary goal is to see whether the data contains distinct, well-separated groups, and when you care about making cluster boundaries as visually crisp as possible. Choose UMAP when you need to embed new data without rerunning everything, when you are tracing continuous processes like developmental trajectories, or when you want to incorporate known labels into the embedding.
Regardless of which you choose, use an informative initialization rather than a random start, bump the main neighborhood parameter well above its default if your data is noisy, and resist the temptation to interpret between-cluster distances or cluster sizes on the final plot. Run the embedding with at least two or three different parameter settings to check that the structures you see are robust rather than artifacts of one particular configuration. And if both methods produce different stories from the same data, that disagreement is itself useful information: it usually points to structure that is ambiguous or scale-dependent in the original high-dimensional space, not to one algorithm being “right” and the other “wrong.”