Tantalum (Ta) has good potential for bone tissue engineering due to its excellent corrosion resistance and biocompatibility. However, the customization of Ta-based bone repair materials for irregularly shaped bone defects has been challenging due to their high melting point and hardness. In this work, porous tantalum granules (PTaG) were developed for the first time to repair irregularly shaped bone defects, inspired by the natural phenomenon of sand flow. PTaG were designed as a hierarchical porous structure to regulate the mechanical properties and provide a favorable space for inward growth of cells and tissues. Commercial porous titanium granules (PTiG) and Bio-Oss were used as positive controls to explore the potential of PTaG as bone substitute. The morphology, three-dimensional structure, composition, and mechanical properties of PTaG and PTiG were evaluated by SEM, X-Ray 3D imaging system, 3D laser confocal microscope, EDS, XRD, XPS, and nanoindentation. In vitro, cell compatibility and mineralization ability were evaluated for both materials. Furthermore, PTaG, PTiG, and Bio-Oss were filled in the rabbit femoral defect, and micro-CT and histological analysis were performed after 8 weeks. The results showed that the PTaG had the best bone healing effect due to the hierarchical porous structure, excellent three-dimensional connectivity and chemical stability, suitable mechanical properties and surface roughness, good biocompatibility and mineralization osteogenic activity. This work indicates that PTaG may have a positive potential for filling and repairing irregularly shaped bone defects.