Suppose you owe a hospital $2,000.
One way to take care of that as a FIREd individual is to withdraw $2,000 from your taxable brokerage account and send that money to the hospital directly. Supposing the shares have a cost basis of $1,000 and you're in the 15% capital gains bracket/22% regular income bracket, that will cost you $150 in taxes.
Another way to take care of that bill is to withdraw $2,000 from your taxable brokerage account, deposit it in your HSA, withdraw it from your HSA, and give it to the hospital. The taxable sale costs you $150 in taxes, same as before, but the HSA contribution gets you $440 back from Uncle Sam that you wouldn't have if you didn't run the money through an HSA first. Your MAGI is also $2,000 lower than if you didn't do the HSA trick, which means your health insurance premiums might be lower than otherwise. Is all that worth the hassle? That's your call.