As other answerers have indicated, 2.5" and 3.5" refer to the width of the drive platters. Most hard drives fall into these two sizes, and most have similar height and length within the same width category.
However, when looking to purchase drives that are of high capacity for their physical size (i.e.: 1+ TB for 2.5" drives), you need to watch out for non-standard drive sizes.
For example, the WD3200BPVT is a Western Digital 320 GB internal 2.5" drive. Its height is 9.5 mm, which is about normal for laptop drives. However, the WD10TPVT - a 1 TB internal 2.5" drive - has a height of 12.5 mm, and will not fit in many laptop hard drive bays.
If you are shopping for a high-capacity drive to go into a laptop today, you'll probably have a hard time finding anything far above 750 GB that will actually fit - let alone any high-speed ones. At this time, the highest-capacity Western Digital drive which runs at 7200 RPM and will fit in most laptops is the 750 GB WD7500BPKT.
*Note: I am not a Western Digital employee or advertiser, nor do I intend to portray Western Digital as the best hard drive manufacturer, or the maker of the biggest or fastest drives. I merely have a personal preference for their products, so it is to them that I generally look when shopping for hard drives and checking out current specifications.
TL;DR: Always be sure to check with the hard drive manufacturer, and the manufacturer of whatever device the drive is intended for, to be sure that the new drive's physical dimensions will fit in the space available within your device. Even between drives of the same width (2.5", 3.5", or otherwise), other dimensions may vary.