Experts say baby boomers will give more than $50 trillion to their heirs. But for many, health care costs will claim the bulk of that wealth.

The story goes that baby boomers are going to give tens of trillions of dollars to their heirs over the next few decades.

The “generational wealth transfer” has become a media fascination, both for its eye-popping size and because it might help younger generations as they face doubts about their financial security.

That shift is already in the works, and will continue for a couple of decades. According to wealth management firm Cerulli Associates, some $53 trillion will be passed down from boomers to their Gen X, millennial and Gen Z heirs, as well as to charities. That includes both gifts during their lifetimes and inheritances afterward.

But the overwhelming cost of health care for older people means most people in those later generations won’t inherit much, even if their elders seem well-off today.