Abstract In this paper, we obtain the best constant and equality condition for a class of mixed-norm Hardy inequalities when weight is power function. By building solving corresponding Euler equation, look optimal One main ingredients to introduce two key auxiliary functions so that equalities are derived.