Knee socks come in two distinct styles, kneehighs and over the knee socks. Regular kneehighs will only go up to (at most) the bottom of the kneecap. In absolute terms they are largely just very long socks.
Over the knee socks differ in that they are designed to be pulled over the knee and rest above the kneecap. At first look they can be mistaken for thighhighs; traditionally, they are slightly shorter than thighhighs and can't be pulled up much more than a few inches above the top of the kneecap. However, currently both terms are often used almost synonymously. Note that in Japan "knee socks" ("ニーソックス") and "knee-highs" ("ニーハイソックス"), "ニーソ" for short, nowadays refers only to thighhighs/over-knee socks, due to the apparel industry having renamed below-the-knee knee-highs to "high socks" ("ハイソックス"), so "knee socks" becamed used only for the very long variant.