Early medieval kings - like those of the Franks, the Visigoths or the Nordic people - were more often than not elected for life.
Arguably the distinction between royalty, nobility and commonfolk grew larger the longer the feudal system was in place, to the point where kings inherited entire countries by birthright at the end of the XVIII century.
In practice, even later English kings were effectively elected and could have their terms ended early. Taking a few Plantagenet examples, the nobles imprisoned Edward II as retaliation for the plots of Hugh Despenser, and then the king died mysteriously (adverb used ironically). Edward III was far more popular with the nobles due to his many victories in Scotland and France. His successor, Richard II, tried to make a lasting peace with France, but that was much less popular with the most powerful burghers and nobles. So Richard II was deposed, imprisoned, and died mysteriously. No doubt if they had security cameras in those days, they would have mysteriously ceased functioning at some critical moment. So ended the Plantagenets and began the line of Lancastrian kings.
I would push back slightly and say that this trend is more even and there is less disruption to it than sometimes historians try to present. E.g. the execution of Charles I during the English Civil War of the 17th century is often presented as a sharp break with tradition, but if one accepts that dissatisfactory kings usually wind up murdered via artful legalism combined with some negligent-jailor theater, it just looks like business as usual.