Anyone who has dabbled in website creation, has no doubt had to wrangle with an image codec. You have to do this because of bandwidth, since images too large will waste time for those on slow connections, and cost you dearly if you're popular.
Since the late-1990s, two dominate image formats came to be used all over the web (and off the web too). JPEG (est. 1992) and PNG (est. 1996). Both these image formats had different use cases. JPEG became infamous for it's lossy compression, widely used with photographs where the loss was less visible. While PNG was better suited to computer graphics, since it supported transparency, and it's lossless compression performs well on uncomplex images.
Before moving on I should also mention that GIF was big at this time. It can be considered a proto-PNG format, because of it's historical use in the same domain. GIF is from the late-80's, so it is limited to 256-colours. However GIF animations are widely supported, so this format lived long past it's expiry date.
JPEG (actually named after the committee who created it), tried as early as the year 2000 to replace the original standard, with "JPEG 2000". They were ultimately unsuccessful dethroning JPEG 1, despite large improvements with it's compression. Meaning it caused less information loss, and looked better then a JPEG image at an equivalent file size. There was also a large range of expansions, such as the support for motion and lossless compression. Ultimately is was probably patents and the associated license costs that prevented JP2 from going mainstream, a lesson which would later be learnt.