The gpu will fit with that MB, because as long as the MB has pciex16 slot. But nobody will know the gpu will work with that HP MB, because the MB is the OEM ( HP), sometime the non OEM GPU has the compatiblity problem with OEM MB.
So if you don't buy that MB yet, may consider to buy the non OEM motherboard.