Money you contribute to a 529 account is generally treated as a completed gift to your student, but as the Account Owner, you still have control over it. If you die with money remaining in your account, it will not be included in your estate for federal estate tax purposes.
However, if you took advantage of the option to treat a single $85,000 contribution ($170,000 for married couples) to a 529 plan account as if it was made over 5 years and you die within 5 years of contributing, a prorated portion of the contribution will be subject to estate tax.
For more information, consult your tax advisor or estate planning attorney. Learn more about tax benefits.