Photos are graphics and the most popular ones for website use are jpg, gif and pgn. So don't confuse html to that please, mate. Html is mark-up language for writing the content of website and it is nothing to do with graphics.
If select the format from above three option, .JPG format is the best for the photos but especially for the photographic images .TIF (Tagged Image File Format) and .PNG (Portable Network Graphics) are the best for the photos within which you will get the best quality of the photos.
Back at school we were told that all images should be PNG. It is like a standard format for images since it is smaller than JPG so the site loads faster.
Also .PNG and .GIF are to be used if you're looking to get the transparent effect with photos, if you were unaware. For example if you wanted to create something to have the background of the page it's on.
PNG is NOT smaller than JPEG -- at least not for photographs; quite the opposite in fact where what can be delivered as a 20k to 60k jpeg at 15% lossy is a half a megabyte file as PNG. Where the devil the people claiming otherwise got their information is beyond me, but talk about needing a double helping of Sierra Tango Foxtrot Uniform! JPEG is the best choice for photographs online if you care about filesize and speed, but be warned it's a "Lossy" format, which is to say the encoding that makes the file size smaller does damage to the photograph. PNG is a lossless format best reserved for things like line-art or comics. Large open areas of the same uniform color encode well, areas of constantly changing color and luminance encode poorly. PNG can also go even smaller on small images by reducing the color depth, though using it that way has to be done with a degree of care and knowledge. It should NOT be used for photographs unless you REALLY don't want any loss/damage -- which is why it's the format you use while developing the site's content, NOT the format you use on deployment. So if you're talking Photographs, that's JPEG, preferably anywhere from 5 to 15% lossy. 5 to 10% lossy will make a typical 'web deployable' 1280x1024 image and compress it down to anywhere from 80 to 200k, without the loss/damage to the image being noticeable unless you zoom in 400% or more -- which is entirely acceptable in most cases. Same thing as a 24 bit PNG is gonna weigh in at a megabyte or more.
Basically you only have 2 options, that is either JPEG or PNG. That is because with GIF, you only get 256 colors and that won't work with continuous-tone images like photographs. Unlike with JPEG and PNG, you get to have 16 million colors, definitely good for photographs / continuous-tone realistic images. As what deathshadow mentioned, JPEGs are for photographs. Again, because it is a lossy compressed file format. That's why it's good for storing photographs at more manageable sizes than a PNG which is a lossless compression file format... which is on the other hand works best for things like line art or comics or any text-heavy images.