A search for the standard model Higgs boson decaying to a charm quark-antiquark pair, H → c c ¯ , produced in association with a leptonically decaying V ( W or Z ) boson is presented. The search is performed with proton-proton collisions at s = 13 TeV collected by the CMS experiment, corresponding to an integrated luminosity of 138 fb - 1 . Novel charm jet identification and analysis methods using machine learning techniques are employed. The analysis is validated by searching for Z → c c ¯ in V Z events, leading to its first observation at a hadron collider with a significance of 5.7 standard deviations. The observed (expected) upper limit on σ ( V H ) B ( H → c c ¯ ) is 0.94 ( 0.50 - 0.15 + 0.22 )pb at 95% confidence level (C.L.), corresponding to 14 ( 7.6 - 2.3 + 3.4 ) times the standard model prediction. For the Higgs-charm Yukawa coupling modifier, κ c , the observed (expected) 95% C.L. interval is 1.1 < | κ c | < 5.5 ( | κ c | < 3.4 ), the most stringent constraint to date.