Realistic fire and smoke simulation using fluid dynamics. Buoyancy drives hot gas upward, turbulence creates flickering flames, and smoke billows and dissipates naturally.
Incompressible fluid simulation with buoyancy (hot gas rises) and temperature-dependent rendering. Vorticity confinement adds realistic turbulent swirls.
Click to ignite new fire sources. Adjust buoyancy, dissipation and vorticity. Watch how fire creates convection currents that shape the smoke.
Jos Stam's "Stable Fluids" (1999) revolutionised real-time fluid simulation. His semi-Lagrangian advection method is unconditionally stable, making it perfect for visual effects and games.
This simulation models the spread of fire and smoke across a 3D grid using cellular-automaton rules, where each cell holds state such as fuel, temperature and ash. On every step a burning cell ignites flammable neighbours according to probabilistic transition rules influenced by adjustable wind direction and fuel density, while smoke rises and disperses above the flame front.
Cellular automata like this capture the emergent, self-organising behaviour of combustion fronts without solving the full Navier-Stokes fluid equations, making them fast enough to run in real time. The same percolation-style dynamics underpin simplified wildfire spread models, game and film visual effects, and research into how fuel breaks and wind shape fire propagation.
What is a cellular automaton?
A cellular automaton is a grid of cells, each holding a discrete state, that updates in synchronous time steps according to fixed local rules based only on neighbouring cells. Despite their simplicity, these rules can produce complex, lifelike global behaviour such as a spreading fire front.
How does fire spread in this simulation?
Each burning cell has a probability of igniting adjacent flammable cells every step. That probability is modulated by wind, which biases spread in one direction, and by fuel density, which determines how readily a cell catches and how long it burns before turning to ash.
Does the wind setting actually change the outcome?
Yes. Increasing wind strength raises the ignition probability for cells downwind and lowers it upwind, stretching the fire into an elongated, directional front rather than a roughly circular spread.
Bright orange and yellow cells are actively burning at high temperature, darker red marks cooling embers, grey indicates spent ash that can no longer burn, and the translucent plume above is rising, dispersing smoke.
It is a qualitative model, not a computational fluid dynamics solver. It reproduces realistic emergent patterns of spread, fronts and burnout, but it does not compute exact temperatures, heat transfer or true turbulent flow.
If ignition probability is low or fuel is sparse, the fire can fail to reach new flammable cells before its current cells burn to ash. This is the percolation threshold: below a critical density, fire cannot sustain a connected path through the grid.
Only if neighbouring cells within the rule's neighbourhood are flammable. Wide unfuelled gaps act like firebreaks and stop the front, which is exactly how cleared strips are used to contain real wildfires.
It sets the fraction of grid cells that contain burnable material. Higher density means more connected fuel and faster, more complete burns; lower density fragments the fuel and can halt spread entirely.
Smoke is emitted by burning cells and advected upward, fading as it disperses. It is a visual layer driven by the same cell states rather than a separately simulated gas, keeping the model lightweight.
Simplified probabilistic spread models inform wildfire risk mapping, evacuation planning and the placement of firebreaks, and the same cellular-automaton approach is widely used for fast fire and smoke effects in games and visual effects.