N-halamine-containing mesoporous silica was prepared by treating the silica with (3-(trimethoxysilyl) propyl methacrylate), followed by grafting reaction of an N-halamine precursor, 3-(3′-hydroxypropyl)-5,5-dimethylhydantoin (APDMH). The resulting N-halamine mesoporous silica was applied to the surface of cotton by a coating process. The coated cotton showed good static and dynamic hydrophobic properties (static contact angle, 138.91°). After soaking in household bleach, N-halamines were formed on the coated fabric, which provided good antimicrobial properties against Gram-positive bacteria, Gram-negative bacteria, and fungi. The chlorinated sample inactivated 98.93% of Staphylococcus epidermidis, 97.83% of Escherichia coli O157:H7 and 82.24% of Candida albicans within 60 min, respectively. The coated and chlorinated samples showed high hydrophobicity toward other water-based liquids such as coffee, cola, green tea and milk. Further, the chlorinated fabric samples degraded ammonia in aqueous solutions. These attractive functions make the new N-halamine mesoporous silica coated cotton fabrics as an excellent candidate of multipurpose functional fibrous materials.