The wear-resistant Ta4HfC5 nanoceramics were prepared via polymer preceramic routes. Tribological behavior of the generated nanoceramics from room temperature to elevated temperatures was investigated. The results shows that the coefficient of friction (COF) of the Ta4HfC5 sliding against Si3N4 first increases and then decreases with the rise of temperature, reaching as low as about 0.20 at 800 °C. The low COF at 800 °C is dominantly ascribed to the formation of oxide tribo-film on the worn surface. The fine microstructure benefiting from the polymer precursor synthesis imposes positive effect to the reduction of friction coefficient at the high temperature.