The infection of bone and bone marrow is called osteomyelitis. Treatment is difficult since antibiotics can not reach with enough concentration to the infected area. For the first time in this study, we have developed gentamicin-loaded magnetic gelatin nanoparticles (GMGNPs) for nanocarrier-mediated and magnetically targeted osteomyelitis therapy. Gelatin, genipin, and magnetite were used for preparation of that novel carrier system due to their biodegradable and biocompatible properties. Cross-linking degree of gelatin nanoparticles, concentration of magnetite nanoparticles, and adsorbed drug amount were optimized. Furthermore, nanoparticles were characterized and the drug release profile was determined. The osteomyelitis model was constituted in the proximal tibia of rats. The therapeutic potential of GMGNPs on rats was monitored via X-Ray radiography and hematological and histopathological analyses were performed. According to the results, 110.3 +/- 8.2 mu g gentamicin/mg GMGNPs were used, hydrodynamic size was measured as 253.7 +/- 11.8 nm, and GMGNPs have controlled drug release profile. Based on in vivo and ex vivo studies, after six doses of GMGNPs treatment, abscess began to heal and the integrity of periost and bone began to reconstruct. In conclusion, it can be suggested that GMGNPs could provide efficient therapy for osteomyelitis.