Preparing images for the web
There are only a few image formats used on the Web, with the most common being JPEG and GIF. The rule of thumb is that JPEG is better for photographic (continuous tone) images. Though an understanding of both is necessary to make the right choice. The difference between JPEG and GIF can be easily illustrated.

Graphics software such as Irfanview (basic / free) or Photoshop (advanced / expensive) allow you to resize and offer a compression scale you set when saving images as JPEG. Online services such as picnik.com can also be used to prepare images. Some web platforms such as Flickr or Wordpress offer automatic image sizing and compression. Nevertheless an understanding of both image compression and image size is important.
Compression

Highest quality (100%).
File size: 15.3Kb image (large images MUCH larger file sizes)
Going for top quality whilst desirable in theory is not best for web use.

High quality (70%).
File size: 6.6Kb image
Very good results with almost no noticable difference in quality yet half the file size so double the speed!
Medium quality (40%).
File size: 3.4Kb image
Some 'artefacts' creeping in with edges no longer looking as sharp as before - acceptable for many images though.
Low quality (10%).
File size: 1.9Kb image
It may arrive on a users screen quickly but if they don't like what they see is it worth it? Distinct 'blockyness' as compression does its worst.
Size
Some useful sizes are:
215 pixel wide = (typically 1/3 'page' width)
325 pixel wide = (typically half page width)
670w X 500h = (often a 'maximum' size before an image is considered 'outsize')
So what about GIF?
GIF images have their place as they are actually better for images with flat colours. One big advantage they have is that they can have a transparent colour so that the background will show through these areas. They can also contain more than one 'frame' and so display simple animations.
PNG is a more recent file format that can have transparency like GIF but full colour like JPEG. PNG images are becoming more common on the internet.