Actually, it's higher in energy once the d-subshell starts to fill....
That's why transition metals lose the ns electron before the (n-1)d electrons...because it's higher in potential energy and thus more readily lost.
The ns subshell fills before (n-1)d because INITIALLY it is LOWER in energy. Therefore, in accordance with Aufbau ordering, ns fills before (n-1)d subshell.
However, once the (n-1)d subshell starts to fill, the d subshell electron(s) exert a shielding effect on the ns electrons....
Now, the ns electron is HIGHER in potential energy.