I usually run one under the sink and get it wet if I need to get gunk off of a fretboard. If the buildup is significant, I’ll use my fingernail under the microfiber cloth to help scrape it off the fingerboard—it’s possible to scratch the fingerboard, but I’ve never done that in this way (with my finger under the cloth itself while removing dirt).
These are cloths I buy. No affiliation or anything—I think they work well.