Onychomycosis, commonly known as fungal nail infection, is a condition where a fungal pathogen, such as dermatophytes, yeasts, or non-dermatophyte molds, infects the nail. It can affect both fingernails and toenails, causing them to become discolored, thickened, and brittle.