HDRI is an acronym for 'High Dynamic Range Image' - which is a term describing a property of a digital image.
A digital raster image is made from lots of individual pixels. For a solid image, without any transparent areas, there are just 2 properties to consider for each pixel - the color (ratio of red, green and blue) and the brightness.
Most digital images you look at have a brightness range from 0 (black) through to 255 (white). That range of values became the standard and is enough to display a good quality photographic image on a computer display. The images on websites still have this value range.
However, in the real world, the range of brightnesses is not limited to an arbitrary value. You can look at a pure white image on this screen, representing the brightest pixel values the screen is able to display, and then look out of the window directly at the sun, and it will be hundreds, if not thousands of times brighter than your computer screen. The digital image on the screen is unable to represent very bright light sources and lighting because the pixel values in the image are limited to 255 maximum and because the computer display has a limited maximum brightness it can display.
So to represent the real word brightness values in a digital image, the brightness value range stored for each pixel needs to increase substantially. In a HDRI, each pixel is stored using a 32-bit value, not an 8-bit value. This means the maximum brightness of a pixel goes up from 255 to a staggering 2,147,483,647. This value range is more than enough to store real-world brightness values.
Since the creation of the term 'high dynamic range image', we now call images that are not high dynamic range, low dynamic range.
A HDRI file is used to store photographic imagery that contains far more detail than a photograph where the dynamic range is limited and lacking detail either in the shadows or highlights.
You can compare an LDR and HDR image by adjusting the brightness of the image in an image editor. All of the image content of an LDR image will fit in the brightness range a computer display can show. Whereas, for a HDR image, adjusting the brightness of the image will reveal lots more image information in the shadows and bright areas. Because it contains more information than can be shown at any one time on the computer display. If you compressed the images range into the display's range, it would look weird, so you only look at the image at a certain exposure at any time.
A HDRI is useful for mapping onto an area light in 3D software. It will provide more realistic lighting because the reflections will contain a wealth of detail not found in LDR images.
In the context of 3D graphics, a HDRI is most commonly used to store a photographically captured view in all directions from a single viewpoint.
This 360-degree spherical image, in a rectangular format, stores the real world values for the lighting and reflections at that location. This image is then used for image-based lighting in 3D software and is mapped onto a lighting dome/sphere. In this context, the HDRI is called a 'HDRI map'. Adding the word 'map' indicates that the rectangular image's content is made for mapping onto lighting environments.
HDRI maps can be created in the following ways:
These methods for making a HDRI are explained in our article: How do you make an HDRI map?
When a 3D scene is lit using a HDRI map, the lighting and reflections from the HDRI map surround the 3D objects in the scene. When the 3D scene is rendered with materials, the HDRI map provides realistic illumination and reflections values for the 3D model, and the render looks like the 3D model was photographed at the captured location.
If the scene was surrounded by an LDR image, the lighting would have very little contrast, and the reflections would not contain enough contrast and detail. Highlights would be far dimmer.
Using HDR maps for the lighting and reflections seen in 3D models provides an easy to use method for lighting a 3D scene and produces photorealistic results. The HDRI map is photographic reality itself, so is bound to make the rendered object look more real.
Because the HDRI map is a view from a single viewpoint - a small light that is close will appear the same size as a large light that is further away on the map. We discuss that further in our article size and distance in HDRI maps.
This video begins with a great explanation of what a HDRI map is and how they are used in computer graphics
HDR image files are larger than LDR image files because they need to store larger numbers for pixel values.
The most common file formats for HDRI maps are .HDR (also called a radiance file) and .EXR files.]
The HDR file format is the oldest. A HDR file can't store an alpha value, and will always be a solid image. There is far less control over this older file format and it has mostly been replaced by the more modern EXR format.
The EXR file format is open source and was created by Industrial Light and Magic. It is a very flexible image format and is used extensively in VFX, not just for HDRI maps, but as a format for storing movie frames. It can store an alpha channel, in fact as many channels as you need for VFX work and compositing. You can also save EXR images with mipmapping, different levels of compression and much more.