The unique luster of pearls depends on the reflection, refraction and diffraction of light from the translucent layers. The finer and more numerous the layers of the pearl, the finer the luster. The iridescence shown by the pearls is due to the overlapping of successive layers, which breaks up the light falling on the surface. Additionally, pearls (especially freshwater cultured pearls) can be dyed yellow, green, blue, brown, pink, purple, or black. The best pearls have a metallic sheen like a mirror.
Since pearls consist mainly of calcium carbonate, they can be dissolved in vinegar. Calcium carbonate is also susceptible to a weak acid solution because the crystals react with the acetic acid in the vinegar to form calcium acetate and carbon dioxide.
Fresh and salt water pearls
Freshwater and saltwater pearls can sometimes look quite similar, but they come from different sources.
Freshwater pearls are formed in several species of freshwater mussels, Unionidae family, which live in lakes, rivers, ponds, and other freshwater bodies. These freshwater pearl mussels are found not only in warmer climates, but also in cooler, temperate areas such as Scotland (where they are protected by law). Most of the freshwater cultured pearls sold today come from China.
Saltwater pearls grow inside the pearly oysters, family Pteriidae, which live in the oceans. Saltwater oysters are generally farmed in protected lagoons or volcanic atolls.
Pearls form inside the shell of some molluscs as a defense mechanism against a potentially threatening irritant, such as a parasite within the shell, or an attack from the outside that damages the mantle tissue. The clam creates lots of pearls to seal in the irritation. Therefore, pearls are the result of a similar immune response in the human body to the capture of an antigen by a phagocyte (phagocytosis). 
The shell of the mollusk (protective membrane) deposits layers of calcium carbonate (CaCO3) in the form of the mineral aragonite or a mixture of aragonite and calcite (polymorphs with the same chemical formula, but with different crystalline structures) joined by an organic horn. compound called conchiolina. The combination of aragonite and conchiolin is called mother of pearl, which forms mother of pearl. The common belief that a grain of sand acts as an irritant is, in fact, rarely the case. Typical stimuli include organic material, parasites, or even damage that moves the mantle tissue to another part of the mollusk’s body. These small particles or organisms enter when the shell valves are open to feed or breathe. In cultured pearls, the irritant is typically a piece of embedded mantle epithelium, with or without a spherical pearl (cultured pearls with or without beads).  
Natural pearls are almost 100% calcium carbonate and conchiolin. Natural pearls are believed to form under a number of accidental conditions when a microscopic intruder or parasite enters a bivalve mollusk and lodges inside the shell. The mollusk, irritated by the intruder, forms a pearly sac of cells of the outer coat tissue and secretes calcium carbonate and conchiolin to cover the irritant. This secretion process is repeated many times, thus producing a pearl. Natural pearls come in many shapes, perfectly round ones are relatively rare.
Generally, the accumulation of a natural pearl consists of a brown central zone formed by columnar calcium carbonate (usually calcite, sometimes columnar aragonite) and a yellowish to white outer zone consisting of nacre (tabular aragonite). In a cross section of beads like the one in the diagram, you can see these two different materials. The presence of columnar calcium carbonate rich in organic material indicates the juvenile coat tissue that was formed during the initial phase of pearl development. Living cells displaced with a well-defined task can continue to perform their function in their new location, often resulting in a cyst. Such displacement can occur due to injury. The fragile edge of the shell is exposed and prone to damage and injury. Crabs, other predators, and parasites such as worm larvae can produce traumatic attacks and cause injuries in which certain cells of the outer coat tissue become disconnected from their coat. Embedded in the connective tissue of the mantle, these cells can survive and form a small sac in which they continue to secrete calcium carbonate, their natural product.