A moderately low risk of investment is a government bond. If I understand correctly, I spend €1000 on a 5-year bond at a yield of 1%, then in 5 years I get back 1000*(1.01)**5=€1051.01, unless the government defaults on its debts, in which case I get zero. If we ignore the option of a partial default, then there are only two possibilities: either I get back exactly €1051.01, or I get back €0 (NB: Apparently my understanding is incorrect here, and I would almost certainly get a non-zero amount of money back even if the government defaults — Thanks to MD-Tech for the correction). This contrasts with stocks, where the value after five years can be anything, with a lower bound of zero and no theoretical upper bound.
I have a online banking brokerage account through which I have a small index fund investment. This account also offers the option to buy government bonds, but they all seem to fluctuate in price from daily, like stocks. This contradicts with my understanding above. It seems that the bonds are all secondhand and that price fluctuations reflect the markets estimate of a government default. That means I can buy a 30-year bond today and sell it next year, at a value which is unknown.
If my understanding is correct, how can I practically buy government bonds that behave such as described in the first paragraph? Is this even available to ordinary people, or do all government bonds get bought by major institutional traders who then resell them on a secondhand market, where they do fluctuate by price daily?
For the purpose of this question, assume I live in a Eurozone member country such as Germany, and want to buy bonds issued in Euros (so that the currency exchange risk is absent).
See also: How can I practically buy stocks?