No you don’t. This is a common myth found in internet bed bug lore.
Bed bugs can hide all over the place, not just in the bed. In general, if it is wooden, paper or fabric and has holes, seams, crevices or cracks — there is a chance they will harbor there and possibly lay eggs. Some hotels have even found that bed bugs hide in remote controls and bed side alarm clocks. Not only that, bed bugs can travel quite a ways to hide. A figure commonly given is 20 feet. We know however that they sometimes travel much farther as bed bug infestations can spread from unit to unit in apartments, condos, hotels and dorms.
So if you throw your mattress and boxspring away, you still have a bed bug problem. If the mattress and boxspring are infested you simply buy encasements for them.
These tough plastic covers completely seal mattresses and boxsprings. Bed bugs can’t get in and they can’t get out. Bed bugs can go quite a while (18 months) without feeding before they will die. So you have to leave the mattress encasements on there for a little longer than that. But they are inexpensive and generally recommended by pest control professionals and entomologists for bed bug control. Mattress Encasements – What does a bed bug mattress cover do? has more information.