In classical antiquity swimming and bathing were done naked. There are Roman murals which show women playing sports and exercising wearing two-piece suits covering the areas around their breasts and hips in a fashion remarkably similar to the present-day bikini. However, there is no evidence that they were used for swimming. All classical pictures of swimming show nude swimmers.
In various cultural traditions one swims, if not in the nude, in a version in suitable material of a garment or undergarment commonly worn on land, e.g. a loincloth such as the Japanese man's fundoshi.
In the United Kingdom until the mid-19th century there was no law against nude swimming, with each town being free to make its own laws. For example, the Bath Corporation official bathing dress code of 1737 prescribed, for men:
It is Ordered Established and Decreed by this Corporation that no Male person above the age of ten years shall at any time hereafter go into any Bath or Baths within this City by day or by night without a Pair of Drawers and a Waistcoat on their bodies
In rivers, lakes, streams and the sea men swam in the nude, where the practice was common. Those who didn't swim in the nude, stripped to their underwear. The English practice of men swimming in the nude was banned in the United Kingdom in 1860. Drawers, or caleçons as they were called, came into use in the 1860s. Even then there were many who protested against them and wanted to remain in the nude. Francis Kilvert described men's bathing suits coming into use in the 1870s as "a pair of very short red and white striped drawers".
Female bathing costumes were derived from those worn at Bath and other spas. It would appear that until the 1670s nude female bathing in the spas was the norm and that after that time women bathed clothed. Celia Fiennes gave a detailed description of the standard ladies' bathing costume in 1687:
The Ladyes go into the bath with Garments made of a fine yellow canvas, which is stiff and made large with great sleeves like a parson’s gown; the water fills it up so that it is borne off that your shape is not seen, it does not cling close as other linning, which Lookes sadly in the poorer sort that go in their own linning. The Gentlemen have drawers and wastcoates of the same sort of canvas, this is the best linning, for the bath water will Change any other yellow
The Bath Corporation official bathing dress code of 1737 prescribed, for women:
No Female person shall at any time hereafter go into a Bath or Baths within this City by day or by night without a decent Shift on their bodies
The Expedition of Humphrey Clinker was published in 1771 and its description of ladies’ bathing costume is different to that of Celia Fiennes a hundred years earlier:
The ladies wear jackets and petticoats of brown linen, with chip hats, in which they fix their handkerchiefs to wipe the sweat from their faces; but, truly, whether it is owing to the steam that surrounds them, or the heat of the water, or the nature of the dress, or to all these causes together, they look so flushed, and so frightful, that I always turn my eyes another way
Penelope Byrde points out that Smollett’s description may not be accurate, for he describes a two-piece costume, not the one piece shift or smock that most people describe and is depicted in contemporary prints. His description does, however, tally with Elizabeth Grant’s description of the guide’s costume at Ramsgate in 1811. The only difference is in the fabric the costumes are made of. Flannel, however, was a common fabric for sea bathing costumes as many believed the warmer fabric was necessary in cold water
In the 18th century women wore "bathing gowns" in the water; these were long dresses of fabrics that would not become transparent when wet, with weights sewn into the hems so that they would not rise up in the water. The men's swim suit, a rather form-fitting wool garment with long sleeves and legs similar to long underwear, was developed and would change little for a century.
In the 19th century, the woman's two piece suit became common—the two pieces being a gown from shoulder to knees plus a set of trousers with leggings going down to the ankles.
In the Victorian era, popular beach resorts were commonly equipped with bathing machines designed to avoid the exposure of people in swimsuits, especially to people of the opposite sex.
In the United States, beauty contests of women in bathing costumes became popular from the 1880s. However, such contests were not regarded as respectable. Beauty contests became more respectable with the first modern "Miss America" contest held in 1921, though less respectable beauty contests continued to be held. Norman Rockwell judged the Miss America 1922 bathing beauty contest along with Howard Chandler Christy and James Montgomery Flagg. They were all unclear as to how to judge the contest. One judge suggested that they judge each part or feature of the body out of ten, then the woman with the total highest score would win. After they had tried the system, they discovered that although one woman might have beautiful individual parts for features, she might not be beautiful over all. So they "...gave up trying to figure out a system and resolved to trust our eyes. It led to squabbles, because all of us didn't see things in the same way, but it was the best we could do
20th century
In 1907, the swimmer Annette Kellerman from Australia visited the United States as an "underwater ballerina", a version of synchronized swimming involving diving into glass tanks. She was arrested for indecent exposure because her swimsuit showed arms, legs and the neck. Kellerman changed the suit to have long arms and legs and a collar, still keeping the close fit that revealed the shapes underneath. She later starred in several movies, including one about her life. She marketed a line of bathing suits and her style of one-piece suits came to be known as "the Annette Kellerman." The Annette Kellerman was considered the most offensive style of swimsuit in the 1920s and became the focus of censorship efforts.
Despite opposition from some groups, the form-fitting style proved popular. It was not long before swimwear started to shrink further. At first arms were exposed and then legs up to mid-thigh. Necklines receded from around the neck down to around the top of the bosom. The development of new fabrics allowed for new varieties of more comfortable and practical swimwear.
Due to the figure-hugging nature of these garments, glamour photography since the 1940s and 1950s has often featured people wearing swimsuits. This type of glamour photography eventually evolved into swimsuit photography exemplified by the annual Sports Illustrated Swimsuit Issue. Beauty contests also required contestants to wear form-fitting swimsuits.
The first bikinis appeared just after World War II. Early examples were not very different from the women's two pieces common since the 1920s, except that they had a gap below the breast line allowing for a section of bare midriff. They were named after Bikini Atoll, the site of several nuclear weapons tests, for their supposed explosive effect on the viewer.
Through the 1950s, it was thought proper for the lower part of the bikini to come up high enough to cover the navel. From the 1960s on, the bikini shrank in all directions until it sometimes covered little more than the nipples and genitalia, although less revealing models giving more support to the breasts remained popular. At the same time, fashion designer Rudi Gernreich introduced the monokini, a topless suit for women consisting of a modest bottom supported by two thin straps. Although not a commercial success, the suit opened eyes to new design possibilities. In the 1980s the thong or "tanga" came out of Brazil, said to have been inspired by traditional garments of native tribes in the Amazon. However, the one-piece suit continued to be popular for its more modest approach.
Men's swimsuits developed roughly in parallel to women's during this period, with the shorts covering progressively less. Eventually racing-style "speedo" suits became popular—and not just for their speed advantages. Thongs, G-strings, and bikini style suits are also worn, typically these are more popular in more tropical regions; however, they may also be worn at public swimming pools and inland lakes. But in the 1990s, longer and baggier shorts became popular, with the hems often reaching to the knees. These were often worn lower on the hips than regular shorts.