"Bones" was a nickname for Doctor Leonard McCoy in multiple realities.
In the prime reality, "Bones" was short for "Sawbones"; this long version was used by James T. Kirk only rarely, usually using the shortened version "Bones" during their service together. (TOS: "The Man Trap", "A Piece of the Action"; Star Trek VI: The Undiscovered Country)
During a 2267 landing party mission on Pyris VII, Kirk made a special point to avoid calling McCoy "Bones", instead using the nickname "Doc", after finding themselves in shackles hanging alongside a skeleton. (TOS: "Catspaw")
After watching a recording by the presumed-dead Kirk in 2268, Spock used the nickname by telling McCoy "Forget it, Bones", although he called it something Kirk would have said. (TOS: "The Tholian Web")
In the alternate reality, James T. Kirk referred to Leonard McCoy as Bones because, as mentioned by the doctor the first time they met, all his ex-wife left him after their divorce was his bones. (Star Trek)