Vanguard Total Stock Market Index Fund Investor Shares (VTSMX)'s expense ratio is 0.14% whereas VTI, its equivalent ETF, has an expense ratio of 0.03%. Why is the expense ratio of an index fund sometimes higher than its equivalent ETF?
Because funds of different share classes are there to cater different account sizes.
The actual equivalent of VTI is Vanguard Total Stock Market Index Fund Admiral Shares (VTSAX) if account size is > US$10,000.
Now you may ask why VTI is 0.03% while VTSAX 0.04%. That is because Vanguard of VTSAX provides service, while the service of VTI is provided by your broker.
To put this into perspective, imagine that a person invested $3,000 (the minimum) into VTSMX (not VTSAX) and makes 1-hour of phone call per year to a Minimum Wage call center in the US, such cost to Vanguard is already $7.5/$3,000=0.25%.
Adding onto base64's excellent answer, an ETF also avoids some of the liquidity costs incurred by open end funds. Since only authorized participants may trade shares directly with a fund, and only in large blocks, the fund manager does not need to worry about buying/selling shares to service individual account holders needs.
Imagine if you needed to cash out of your fund and your fund manager had to sell a portion of their portfolio to generate the cash to meet your request? That's expensive. The ETF model uses the market and active participants to handle these types of requests and, hopefully, passes the savings along in the form of lower expenses.