<img class="styles__noscript__2rw2y" src="https://s.w-x.co/util/image/w/GettyImages-467696582.jpg?v=at&w=485&h=273" srcset="https://s.w-x.co/util/image/w/GettyImages-467696582.jpg?v=at&w=485&h=273 400w, https://s.w-x.co/util/image/w/GettyImages-467696582.jpg?v=ap&w=980&h=551 800w" > A worker cleans the panels in a solar power park run by the Costa Rican Electricity Institute in Guanacaste, Costa Rica, in 2015. This year, the power company produced all of the electricity for the nation from renewable energy sources for 300 days. (Joe Raedle/Getty Images)

At a Glance 2018 is the fourth year in a row Costa Rica generated more than 98 percent of its electricity from renewable sources.

For 300 days, the country used no fossil fuels to make electricity.

Costa Rican President Carlos Alvarado wants to launch a plan in 2021 to eliminate fossil fuels from transportation.

For the fourth consecutive year, Costa Rica has generated more than 98 percent of its electricity using only renewable sources.

For 300 days, Costa Rica used no fossil fuels to create electricity , the Costa Rican Institute of Electricity announced this week. The last time the country had to use hydrocarbons to make electricity was May 17.

Hydroelectric plants generated nearly 74 percent of Costa Rica’s electricity this year, followed by wind at more than 15 percent, geothermal at just over 8 percent, and biomass and solar both at less than 1 percent.

(MORE: Monkeys in Costa Rica Are Turning Yellow)

Those five sources were responsible for 98.56 percent of the country's electricity this year, according to the electricity institute. It's the fourth consecutive year the figure has topped 98 percent. In 2015, it reached 98.99 percent; in 2016, it was 98.21 percent; and in 2017 it reached 99.67 percent.

By comparison, renewable sources generate about 17 percent of electricity in the United States .

While fossil fuels have all but been eliminated from the electric grid, Costa Rica still relies heavily on gas and oil for heating and vehicles.

(MORE: Facebook Commits to Using 100 Percent Renewable Energy by 2020)

Monica Araya, a Costa Rican clean development adviser, told Newsweek something is missing from the 300 day achievement.

“It hides a paradox, which is that nearly 70 percent of all our energy consumption is oil,” she said.

<img class="styles__noscript__2rw2y" src="https://s.w-x.co/util/image/w/GettyImages-956113052.jpg?v=at&w=485&h=273" srcset="https://s.w-x.co/util/image/w/GettyImages-956113052.jpg?v=at&w=485&h=273 400w, https://s.w-x.co/util/image/w/GettyImages-956113052.jpg?v=ap&w=980&h=551 800w" > Costa Rica's President Carlos Alvarado arrived at his inauguration on May 8, 2018, aboard a hydrogen-fueled bus. (Ezequiel Becerra/AFP/Getty Images)

Costa Rica's President Carlos Alvarado announced at his inauguration in May that by 2021, the country would start to implement a plan to end fossil fuel use in transportation , the Independent reported.

"Decarbonization is the great task of our generation and Costa Rica must be one of the first countries in the world to accomplish it, if not the first," Alvarado said.

Araya said focusing on removing fossil fuels from transportation could send a strong message to the world.

“Getting rid of fossil fuels is a big idea coming from a small country. This is an idea that’s starting to gain international support with the rise of new technologies,” she told the Independent.