Under the auspice of Anglican priest Archdeacon George Mason, Hoapili was educated at the
Anglican boarding schools: the Luaehu School in
Lahaina,
Maui and the
St. Alban's College in
Honolulu. He was educated alongside
Samuel Nowlein and
Curtis P. Iaukea. At a young age, Hoapili showed a strong interest in military affair. He began his service to the Hawaiian monarchy as a royal guard officer and became a
lieutenant on the Household Guard of King
Kalākaua. He was elected to the House of Representative, the lower house of the
legislature of the kingdom, for the Kona district of
Oahu (around Honolulu). He sat in on the legislative assembly of 1880. During this session, he proposed the creation of a
governmentally funded study abroad program which funded the international study of a number of Hawaiian youths from 1880 to 1892 in Italy, Scotland, England, the United States, China and Japan. On August 12, 1884, Kalākaua appointed him as a member of the Privy Council of State. From October 4, 1886 to August 23, 1888, Hoapili was appointed to succeed
John Owen Dominis as
Governor of Maui, and the adjacent islands of
Molokai and
Lanai. He did not hold the post for long. The royal island governorships were abolished by the legislature after the
Bayonet Constitution. The king had vetoed the bill, but the new constitutional changes, which limited the king's executive power, allowed the legislature to override his opposition. Hoapili continued serving the king on his Privy Council. On May 15, 1889, he became
aide de camp and a member of King Kalākaua's military staff with the military rank of
colonel. He continued as a privy councilor and advisor of the king. with Colonel Macfarlane and Colonel Hoapili Baker aboard the
USS Charleston en route to San Francisco, California Regarded as a close friend and confidante, Hoapili accompanied the king on his final visit to the United States aboard the
USS Charleston, in November 1890. Colonel
George W. Macfarlane, the King's Chamberlain, was also part of the suite. While visiting Southern California, the king drank excessively and fell ill in January 1891 and had to be returned to San Francisco. The tearful Hoapili and Macfarlane were at his deathbed at San Francisco's
Palace Hotel; he sat at the head of the bed clasping the king's left hand. Shortly before he died, Kalākaua's voice was recorded on a
phonograph cylinder. Kalākaua died on January 20, 1891. The recording was given to Hoapili to take back to Honolulu and he reportedly "guarded it as sacredly as his own life". And it is now in the
Bernice P. Bishop Museum. Among the chief mourners at King Kalākaua's funeral, Colonel Robert Hoapili Baker stood at the head of the casket and was tasked with carrying the
crown,
sceptre and sword of the late King during the final procession. Returning to Honolulu, his military and political commissions were renewed on March 7, 1891, and he remained on the military staff and Privy Council of State of Queen
Liliuokalani until the
overthrow of the monarchy in 1893. After the overthrow and the establishment of the
Republic of Hawaii, Hoapili took the oath to the new regime. During this period, he served as member of the Board of Registration of Electors for Oahu. Otherwise, he remained outside the political arena and retired to a private life. and after a royal funeral befitting his rank, conducted under the rites of the
Reorganized Church of Jesus Christ of Latter Day Saints, he was buried at the cemetery of the
Kawaiahaʻo Church. ==Personal life==