The term shows up in credits as "Best Boy Electric" or "Best Boy Grip." Imdb explains the origin of the term thus:
The origin of the term is from "pre-union" filming days when the line
between Grip [department dealing with cameras and other equipment] and
Electric departments was less rigid. When the head of either
department needed another body temporarily, he'd go to the head of the
other department and ask him to "lend me your BEST boy". By default
the 2nd in charge of either department came to be known as best-boy.
This exact wording appears in multiple places across the internet, sometimes with attribution to IMdb and sometimes without. Imdb gives no source for its explanation, which sounds like folk etymology to me.
Long before the film industry came about, English public schools had the office of "best boy," or teacher's assistant, described here in an 1892 issue of The Public School Journal:
Not only can the best boy in school light cigarettes for his
but he becomes the monitor of the school room when the teacher is
hearing recitations.... [H]e patrols the aisles of the school room,
... calling the other boys to order....
The term was also used on sailing ships for the captain's apprentice as recorded in the journal The Nineteenth Century and After in a 1921 article called "Sea Service" which reported on an apprentice's drowning:
The captain was almost overcome by the loss of 'his best boy.'
You can find claims that early movie crews were made up longshoremen and sailors. (See this Forbes article, for instance.) Again, no sources are cited.