Practices vary by airline.
For example, when a Southwest flight has a single flight number with one or more stops, it is the same plane flying through under normal circumstances -- no need to connect. When shopping for flights on Southwest's web site, only the number of stops is given for such a flight, in contrast to connecting flights, where the connecting airport(s) are listed.
But a single flight number on United does not avoid a plane change and connection (e.g. UA 888, which flies a 747 from PEK to SFO, then an A319 from SFO to LAX). When shopping for flights on United's web site, the number of stops is given, along with a "Plane change" link -- clicking on that link shows what types of planes are flying each segment.