To determine the cause of a nail problem and diagnose a fungal nail infection, your doctor:
Will ask about your medical history, including any previous symptoms of nail damage or fungal nail infections.
Will look at the skin and nails on your hands and feet.
May take a sample of the bits of skin and nail fragments (debris) from under the infected nail. If a sample of debris can't be taken easily, a nail sample may be taken by lightly scraping the nail near the infected area or by using a small blade to shave off a piece of nail.
Tests used to examine nail and debris samples include:
A fungal culture. This can show which type of fungus is present. Fungi typically grow slowly, so it can take several weeks for a culture to produce test results.
Almost all fungal toenail infections are caused by a type of fungus called a dermatophyte. Because of this, if the KOH test shows that there's a fungus present, your doctor may assume that the infection is caused by a dermatophyte and prescribe treatment. But because one medicine may work better than another medicine against certain types of fungus, your doctor may want to do a fungal culture.
Your doctor may remove a small piece of nail and look at it under a microscope (nail biopsy) if the KOH preparation and fungal culture do not show the presence of fungi but a fungal infection is still suspected.