Bed bug mattress covers are more properly known as bed bug encasements. They are available for both mattresses and box springs. If you can afford both, then you should probably get both. If you can only afford one however, buy a bed bug encasement for the box spring.
Bed bug treatment for mattresses is fairly straight forward: you find bed bugs and you kill them. Box springs are harder to treat however.
Box springs have a more complex construction than mattresses. Usually there is plastic hardware on the bottom and staples that hold a mesh onto the bottom. Bed bugs can hide and lay eggs under and around the hardware and the staples. And what is worse is that they can get underneath the mesh and infest the inside of your box spring. While it’s possible to remove the mesh, the inside of a box spring itself can be tricky to properly treat.
So if you only have enough money for one encasement, make it the box spring.