This Reddit comment distinguishes the two. I edited it to rectify typos.
if the bond expires when I hold the ETF, or if interest rates go up, aren't I holding a worthless ETF?
You've got at least two big misunderstandings right there, which is why you are worried.
(edit: Which is totally normal for somebody new to bonds, no problem.)
1) Misunderstanding about how bonds work.
"If the bond expires" - bonds don't "expire", they mature. It sounds like you are thinking they are options or some other derivative that expires worthless if not exercised. That's not what a bond does, not what a bond is.
A bond, simply put, is a loan. "You give me X amount of money for Y amount of time, and at the end of that time I will give you all of your X amount of money back. Plus for you trusting me, I will pay you N% interest on your loan. So you don't have to wait, I will pay you a part of that N% every short period of time during that period."
Now let's put some real-sounding figures on that:
X = "Loan amount" (Bond face value): $1000
Y = "amount of time" (Bond term in years): 5 years
N = percent (Bond interest rate): 3%
"short period of time" = distribution or coupon frequency: monthly
On this example of what might have been a realistic corporate bond from a couple of years ago, let's pretend it was issued Dec 31, 2015, people (and funds) that bought it when it came out, paid $1000 per bond. Each year, assuming they have not sold the bond (sold to somebody else; normally you can't sell it back to the company or government or agency that issued it), they get 3% interest every year, paid out in monthly distributions. So 1000*.03/12=$2.50 payout every month.
On Dec 31, 2020, the end of that bond's lifespan, the bond does not "expire", it matures: This means, each owner of one of those $1000 bonds gets her $1000 back, plus gets the final month of $2.50 interest.
The money doesn't disappear. (I'm using a simple example here, ignoring things like the company going bankrupt or defaulting on its bonds.)
2) Misunderstanding about what a bond fund does. ("fund" here means both mutual and exchange-traded fund.)
Except for a very few bond funds that are deliberately designed to "work like an individual bond", namely the "BulletShares" from Invesco (formerly from Guggenheim, which sold its ETFs to Invesco), or the iShares iBonds series of ETFs from BlackRock, bond funds do not have a maturity date when the fund itself expires.
What a "normal" bond fund does, is have a targeted maturity, or a targeted range of maturities, for the type of bonds its managers buy in the fund. (Yes, its managers, even if an index fund. Managers have to direct traders to find bonds for sale, at the right price, that best replicates the index they are tracking.)
So a short-intermediate-term bond fund, which may be targeting 3-to-5 year maturities, may well be holding some of that same bond I used in my example. But by now, when it only has less than 2 years of life left, they probably have sold it out of their portfolio (or transferred it to the same fund company's short-term bond fund targeting 1-to-2-year maturities). They've bought replacements for that bond.
A regular bond fund, which is all of them except for those target maturity types, which are NOT what most people think of when they thing of "bond funds", does not hold all its bonds until maturity. Nor does it buy all of its bonds when they are first issued. It is instead regularly trading in and out of bonds, some new(ish) that have maturities similar to its goal, some much older that have only the limited few years of maturity left. (A 20 year bond with 3 years left is more-or-less the same thing as a 3 year bond just issued - to a new buyer, they are both 3 year bonds.)
Again, this is oversimplified, and ignores the whole duration-vs-maturity issue. And ignores the "if the interest rates go up, the value of existing bonds go down, and vice-versa" thing.
But for that, imagine that 20 year bond I just mentioned - issued back in 2000 at let's pretend 8% back then for a 20-year lower-investment-grade corporate bond.
Well, somebody buying that $1000 bond now, is NOT gonna get 8% interest on it, because that is ridiculously higher than what bonds 2-year bonds pay now. But they still are going to get monthly coupon payments based on 8% of $1000 divided by 12. How does that end up working out? They are going to have to pay much more than $1000 to buy "$1000 worth of bond", an amount that makes it only worth about 2.5 or 3 percent interest for that 2 years left. Which is about what a newly-issued 2 year bond of similar quality would offer.
Your bond fund, is buying and selling bonds, at capital gains or capital losses on the principal, to keep the fund's average maturity in line with that the prospectus says is its stated maturity goal.
If the fund is an ETF, it probably is not actually created capital gains nor losses that would pass on to you, because an ETF can basically unload those by "taking apart shares" into the individual securities. (Creation or destruction by authorized participants of creation units.) If it is a Vanguard-brand mutual fund, it likely also will not have reportable capital gains/losses, because Vanguard ETFs (and because of a Vanguard patent, only Vanguard ETFs) are simply different share classes of the same overall investment pool as the equivalent mutual fund.
A Vanguard mutual fund can "unload" its capital gains onto the ETF side of the same portfolio, where the creation/destruction of ETF shares into individual securities avoids that. Sometime after 2020, when Vanguard's patent expires, maybe other fund sponsor firms that do both ETFs and mutuals may start doing that, but it's Vanguard-only for now.
This is what's going on inside your bond fund. Buying and selling all the time so that it always has bonds that make up the fund's expected maturity.