Before the advent of indoor plumbing, toilets were made of wood and were placed in the backyard of a home. These outhouses tended to breed bacteria that could be hazardous to one's health, and since wood is quite porous, the buildup of mold, mildew, bacteria, and general filth was likely. Porcelain toilets are not as porous as wood and some other materials, which means they are less likely to accrue such filth. The aesthetic of porcelain toilets is also much more pleasing and cleaner looking than some other materials.
Determining if porcelain toilets are dirty is also generally much easier, which means a homeowner is more likely to clean the unit more regularly. The process of cleaning porcelain toilets is fairly easily, since filth is less likely to be deeply ingrained in the material. The non-porous nature of porcelain ensures this, and other materials such as wood or even some types of metal may be more difficult to clean because the filth and dirt can become deeply ingrained. Porcelain will not rust or corrode, giving it an advantage over most metals.
Porcelain toilets are also fairly inexpensive to manufacture, since the porcelain can be molded and colored easily. Stainless steel is often cited as a good alternative to porcelain, and some toilets and other bathroom fixtures are indeed made from stainless steel, but this metal is more difficult to manufacture, so the cost of the unit is likely to be consequently higher. Cleaning stainless steel is also not quite as easy as cleaning porcelain. While stainless steel is certainly lighter and quite easy to install, the manufacturing process and subsequent pricing of the stainless steel unit is usually enough to be a deterrent for most homeowners.
The look of porcelain is also a significant draw for most homeowners. The porcelain can be colored to match just about any bathroom aesthetic, and a plain white toilet is usually inexpensive and able to blend in with just about any decor. The ease with which the porcelain can be cleaned also helps ensure a high-quality aesthetic; some materials may have a filthy or uninviting appearance even after it is cleaned, but porcelain tends to have a shine that reassures users of its cleanliness. The comfort of the toilet can also be ensured, since the porcelain can be molded easily to create comfortable shapes.