A new nanohybrid photocatalyst Ni@TPP–HPA is introduced as an effective mediator for N2 photofixation. This nanophotocatalyst can be easily recycled without losing its activity for at least five runs to achieve the maximum ammonia generation of 2760 μmol L−1 g−1 under mild conditions.