In medieval Europe, within the Holy Roman Empire, a Hofmeister (literally "court-master" or "house-master" in German; Latin: Magister, Praefectus curiae; Danish: hofmester, hovmester, Swedish: hovmästare, Czech: hofmistr, Polish: ochmistrz; French: précepteur; Italian: precettore / istitutore) was an official who acted as an aide to royalty or to a senior nobleman or cleric.
His official role was initially in the direction of the royal household and serving privately on the monarch's person.
In the 15th century it became a government office and in the German princely courts finally became equivalent to a privy counsellor or cabinet minister, and sometimes as something like the Master of the Household in the modern British royal court.
A Hofmeister was also the title given to someone who acted as an adlatus or aide to his abbot in a monastery.
It gave its name to Der Hofmeister, a play by Jakob Michael Reinhold Lenz.