In the old days, you'd take the time between two "fixes". A fix could be a visual reference, or a NAVAID. That'd result in your shadow's speed.
Then came DME, distance measuring equipment. I don't know if DME ever took altitude into account or if the error resulting from altitude was just ignored, but analog DME radios would just tell distance at first and then digital versions had a groundspeed feature. At least instrument rated pilots were aware of the increasing error the closer to the NAVAID.
At some point in the ATC radar system, a controller's screen could show groundspeed. Pilots can ask ARTCC what ground speed is, although I would never ask approach or departure control such a question. This would have the same error as DME.
Today it's a value reported by GPS. I don't know if this is based on the plane's movement, or its shadow, or if there's a regulation that dictates it for aviation certified GPS. From a pilot perspective we don't distinguish between kinds of ground speed, whereas we do distinguish between kinds of airspeed: indicated, calibrated, and true. Mainly groundspeed is important navigationally to know if there's an unexpected headwind that'll lengthen enroute time and thus impact fuel management. And while there can be big enough error between estimated winds aloft and actual that this computation will affect enroute planning, I tend to only care about tens of minutes or hours, not seconds.