Pipe thread is a spiral ridge on the end of a pipe that enables pipes to be joined together. For male fittings, this thread appears on the outer diameter of the pipe; if female, it appears on the inner diameter. By rotating a male pipe end into a female thread, the two fittings become joined.
Since male and female threads must align successfully to form a connection, manufacturers follow industry standards. The two main standards are the National Pipe Thread (NPT), and the National Standard Free-Fitting Straight Mechanical Pipe Thread (NPSM). NPT is a tapered thread that can make a close-fitting wet seal. NPSM is straight and only forms a mechanical seal; it is not used for liquid applications. In the United States, garden hoses have their own standard (GHT), as do fire hose couplings, which use the National Standard Thread (NST).
When joining NPT tapered pipe thread to make a leak-proof seal, professionals recommend using a sealer such as polytetrafluoroethylene (PTFE) tape. PTFE, more commonly known as Teflon®, is also the name of the best known brand of sealing tape. Tape should be wound tight around the male threads, running in the same direction as the lead thread so that the turning motion of joining the pipes follows the tape's winding direction. Sealing tape makes it easy to drive the male pipe deeper by allowing the threads to slip past one another, while filling minute gaps to prevent seepage. Pipe thread tape also makes it easier to disassemble the joint later, if need be, by reducing thread galling, or the tendency of some types of threads to stick together over time.
Modern pipe sizes are stipulated by a measurement of the outer diameter (OD), which is measured over the pipe thread in the case of a male pipe. To be sure that the threads will match, you can also count the threads per inch (TPI). The inner diameter (ID) is sometimes used when buying polyvinyl chloride, or PVC, pipes.
Building codes require that piping meet certain standards depending on the application. Pressurized gas or liquid, natural gas, potable water and underground drainage pipes will be made of different materials. Note that local laws might require that only licensed contractors work on gas lines. Before undertaking any home piping project, check local building codes and take proper safety precautions.