An MTJ in an MRAM array or TMR read head is disclosed in which a capping
layer has a bilayer configuration with a non-magnetic NiFeX inner layer
on a NiFe free layer and a Ta layer on the NiFeX layer to improve dR/R
and minimize magnetostriction. Optionally, a trilayer configuration may
be employed where the Ta layer is sandwiched between an inner NiFeX layer
and an outer Ru layer. The X component in NiFeX is preferably an element
having an oxidation potential greater than Ni or Fe such as Mg, Hf, Zr,
Nb, or Ta. NiFeX is preferably formed by co-sputtering a NiFe target with
an X target at a forward power of about 200 W and 50 W, respectively. In
an MRAM structure, the Mg content in NiFeMg may be increased to >50
atomic % to improve the gettering power of removing oxygen from the free
layer.