A heatmap is a data visualization that uses color to represent values, turning rows of numbers into patterns you can spot instantly. Where a spreadsheet forces you to scan individual cells, a heatmap lets you see which values are high, which are low, and where clusters form, all in a single glance. The technique shows up everywhere from website design to stock trading to genetic research, and the core idea is always the same: warm colors (reds, oranges) mark high values, cool colors (greens, blues) mark low ones, and everything in between falls on a gradient.
How Heatmaps Turn Numbers Into Color
Every heatmap starts with a dataset that has at least two dimensions and a value at each intersection. Think of a table where each cell gets filled with a color instead of a number. The software maps the lowest value in your dataset to one end of a color scale and the highest value to the other end, then assigns every data point a shade based on where it falls in that range.
There are two broad approaches to this color mapping. A continuous scale (sometimes called a “smear”) uses tiny gradations that blend smoothly from one color to the next, which is useful when you want to show the general direction of change across a surface. A discrete scale groups values into bins, each with its own distinct color, making it easier to categorize data into “low,” “medium,” and “high” ranges. Choosing between them depends on whether you care more about spotting exact thresholds or understanding overall flow.
Website and App Design
This is probably the most common context people encounter heatmaps. Web heatmaps track what visitors do on a page and overlay that activity as color on a screenshot of the site. Several distinct types capture different behaviors:
- Click heatmaps show where users click, revealing whether people are hitting your buttons, tapping on images that aren’t actually links, or ignoring your main call to action entirely.
- Scroll heatmaps show how far down the page the average visitor gets before leaving. If 70% of your audience never reaches the signup form at the bottom, you know to move it up.
- Attention heatmaps measure time rather than distance, showing how long users spend on each section of content.
- Movement heatmaps track where the mouse cursor travels, which roughly correlates with where people are looking.
These tools also track more granular metrics. A hover-to-click rate, for example, tells you what percentage of people who paused their cursor over an element actually clicked it. A low rate signals hesitation: visitors are interested enough to hover but not convinced enough to commit. Time-before-click measures how long it takes the average user to click a specific button, which can flag confusing layouts or unclear copy.
Conversion rate optimization teams use all of this to remove friction. If a click heatmap shows users repeatedly clicking a non-clickable element, you either make it clickable or redesign it so it stops looking like a button. If a scroll heatmap shows attention dropping off at a certain point, you place your most important content or calls to action above that line. Ecommerce teams use the same data to smooth out checkout flows, identifying where shoppers hesitate or abandon their carts.
Eye-Tracking Research
Eye-tracking heatmaps work on the same principle as web heatmaps but measure something more precise: where people actually look. Specialized cameras track a participant’s gaze as they view a screen, product package, or advertisement, recording both where their eyes land and how long they stay. Red and yellow spots mark the areas that drew the most attention. Green and blue areas got less. Blank zones were essentially invisible to the viewer.
UX designers use eye-tracking heatmaps to verify whether key elements like navigation menus, buttons, and headlines are actually being noticed. Researchers use them to study reading behavior, learning efficiency, and how people make decisions. A retail brand might eye-track shoppers looking at a shelf display to find out which product placement draws the most visual attention, then redesign packaging or positioning based on those patterns.
Financial Markets
Stock market heatmaps give investors a snapshot of how an entire index or sector is performing. Each stock appears as a rectangle, with the size of the rectangle representing market capitalization (the largest companies get the biggest tiles). The color of each tile shows performance: green for gains, red for losses, with intensity reflecting the magnitude of the change.
Platforms like Barchart let you toggle between time frames and swap the underlying metric from market cap to price-to-earnings ratio, earnings per share, dividend yield, or volatility (measured as 60-month beta). This flexibility makes heatmaps useful for different types of analysis. A day trader might check the daily percent change across the S&P 500 to spot which sectors are moving. A long-term investor might switch to dividend yield to scan for income opportunities. In either case, the heatmap compresses hundreds of data points into a single visual you can read in seconds.
Geographic and Spatial Analysis
Geographic heatmaps plot data density onto real maps. Instead of a grid of cells, they use smooth color gradients to show where events or phenomena are concentrated in physical space. Urban planners use them to visualize crime density across a city, identifying hotspots where incidents cluster. Environmental scientists map the distribution of endangered species across a region. Emergency management teams track wildfire frequency or the spread of forest fires tied to agricultural burning.
These spatial heatmaps differ from the grid-based type in an important way. Grid heatmaps are abstract: the rows and columns can represent anything. Spatial heatmaps maintain geographic accuracy, preserving the real distances and positions of data points on a map. This means patterns that depend on location, like a cluster of traffic accidents at a specific intersection or a pocket of air pollution downwind from a factory, remain visible rather than getting averaged out into a table.
Biological and Genomic Research
In biology, heatmaps are a standard tool for visualizing gene expression data. A typical genomic heatmap is a massive grid where each row represents a gene and each column represents a sample (a patient, a tissue type, or a time point). The color of each cell shows whether that gene is highly active, moderately active, or dormant in that particular sample.
What makes these heatmaps especially powerful is clustering. Algorithms automatically reorder the rows and columns so that genes with similar activity patterns end up next to each other, and samples with similar profiles group together. This lets researchers spot which genes behave alike across conditions, which can reveal biological pathways, subtypes of a disease, or the effect of a drug on thousands of genes simultaneously. The technique dates back further than most people realize. While it became a staple of genomics in the late 1990s, the earliest shaded matrix table appeared in 1873, created by the French statistician Toussaint Loua.
Grid Heatmaps vs. Spatial Heatmaps
Most heatmaps fall into one of two categories. Grid heatmaps (also called matrix heatmaps) display data in a two-dimensional table with color-coded cells. They’re the most common and versatile type, good for anything from comparing product sales across regions and months to showing gene expression across samples. The axes can represent any categories you choose.
Spatial heatmaps, by contrast, are anchored to a real surface: a geographic map, a webpage screenshot, or a photograph of a product. Point-density heatmaps are a subtype that show concentrations of events, like taxi pickups in Manhattan or earthquake epicenters along a fault line, as smooth gradients rather than discrete cells. The tradeoff is that spatial heatmaps require location data and more processing power, while grid heatmaps work with any structured dataset.
Getting Reliable Results
A heatmap is only as good as the data behind it. In web analytics, a heatmap based on 15 visitor sessions will show you random noise, not meaningful patterns. The sample size you need depends on how subtle the pattern is. Detecting a large, obvious difference (say, 80% of users click one button while 5% click another) requires as few as 26 observations. A medium-sized difference needs around 64. Small differences, the kind that separate a 3% conversion rate from a 3.5% rate, require roughly 394 data points to be statistically meaningful.
For website heatmaps, this means collecting enough sessions on a specific page before drawing conclusions. Most analytics tools will aggregate data over days or weeks to build a reliable picture. If you’re testing a redesign, running the heatmap for a few hours on a low-traffic page will give you a colorful image that means nothing. The visual confidence of a heatmap can be misleading: the colors look authoritative whether they’re based on 20 visits or 20,000.
Common Heatmap Tools
For website heatmaps, the most widely used tools span a range of price points and specialties. Microsoft Clarity is free and covers click and scroll heatmaps, making it a solid starting point for basic questions about user behavior. Hotjar pairs heatmaps with user surveys for UX research. Crazy Egg focuses on visual reporting and integrates with A/B testing. Contentsquare serves enterprise ecommerce teams with journey-level analysis. Mouseflow, Lucky Orange, and Smartlook offer varying mixes of heatmaps, session recordings, and funnel tracking at different price tiers.
Outside of web analytics, the tools change entirely. Financial heatmaps are built into trading platforms and market data sites. Geographic heatmaps are created in GIS software like ArcGIS. Scientific heatmaps are generated in programming languages like R and Python, or in specialized bioinformatics platforms. The concept is identical across all of these; only the data source and the software wrapper change.

