The 67-year-old governor who had been convalescing after undergoing pancreatic surgery in April, had slipped into a "state of clouded consciousness" earlier in the day, according to local officials.
He had been hospitalized since July 30 as cancer had metastasized to the liver, said officials.
Onaga, elected governor of Okinawa in 2014, was well known for his stance against the over-abundance of US bases and personnel in Okinawa, Japan's southernmost prefecture.
He was also a firm opponent of the central government's plan to transfer the US Marine Corps Air Station Futenma to the Henoko coastal area of Nago from a crowded residential district in Ginowan, Okinawa.
Before hospitalized, Onaga said on July 27 that he has again ordered procedures to be started to retract landfill work approval, which was seen by the public as a last resort for the governor to stop the relocation plan.
"I will take whatever measures and do my utmost to realize my election pledge of preventing the construction of a new base," Onaga told a press conference.
Japan's top government spokesman, Chief Cabinet Secretary Yoshihide Suga told a press conference in Tokyo on the same day that the central government's intention to proceed with the relocation construction was unchanged and they would respond "appropriately" to Onaga's efforts to stop the relocation plan.
Okinawa revoked in October 2015 an approval issued by former governor Hirokazu Nakaima for the landfill work of a relocation plan of the central government.
However Onaga was forced to withdraw his order to suspend work on the site after the Supreme Court ruled in 2016 against the governor's attempt to revoke the land reclamation work approval.
Onaga's new retraction order was based on the ground that situation had changed and the central government had failed to protect the environment of the coastal area since resuming the construction work.
Okinawa hosts the bulk of US bases in Japan while accounting for only 0.6 percent of the country's total land mass.
Japan's central government had said that the relocation plan is "the only solution" for removing the dangers posed by the Futenma base to the crowded residential area of Ginowan without undermining the Japan-US alliance.
The Okinawa people, however, have called for the base to be removed from the prefecture, complaining of sufferings caused by aircraft noise, crimes committed by the US servicemen as well as safety concerns.
Okinawa Deputy Governor Kiichiro Jahana said at a press conference earlier in the day that he had a meeting with Onaga at the hospital on Aug. 4 and that he would represent Onaga to attend a prefectural gathering later this week to protest against the relocation plan and read Onaga's message to the gathering.
Under the Japanese election law, the gubernatorial election to choose Onaga's successor will be held within 50 days.