This quick guide explains how you can fix the LibreOffice requires a Java runtime environment (JRE) error.
LibreOffice – the free office suite requires Java runtime environment for some of its own functionalities. For example, some of the plugins, extensions, Python macros require Java Runtime Environment (JRE) to work.
Lack of JRE, would cause the below error in LibreOffice:
LibreOffice requires a Java runtime environment (JRE) to perform this task. Please install a JRE (and libreoffice-java-common) and restart LibreOffice.
This happens when JRE is not installed in your OS – be it either Windows or Linux. Before you go ahead and try to fix via installing JRE, first you have to check whether Java Runtime Environment is installed in your system or not.
How to check if LibreOffice detected Java Runtime Environment
Before you install Java Runtime Environment to fix the issue, follow the below steps to check whether Java is installed and LibreOffice is able to detect it.
- Open LibreOffice (calc, Impress, etc).
- Go to from Menu :
Tools -> Options -> Advancedunder LibreOffice.
- Under Java Options window, if Java is installed you would see it listed. If not, there will not be any entries.
How to Fix JRE Error – LibreOffice
- Download Oracle Java Runtime Environment from below the official link and install it in Windows. This link will take you to manual installation for Windows 10 with an offline installer. Select “Windows Offline (64-bit)”.
- After downloading, click on jre-***.-windows-x64.exe to install. It should open up a window like below. Do not change the destination folder. Click Install.
- After successful implementation, you should see below.
- Now its time to verify Java installation in Windows. By default Java setup installs it in C:\Program Files\Java\jre1.8.0_231
- Close all the LibreOffice instances.
- Restart LibreOffice and perform the task which gave you the error. You should not be receiving the error anymore.
- Verify from Tools -> Options -> Advanced that LibreOffice detected the Java runtime correctly.
Linux, Ubuntu, RHEL, Fedora
- If you are running Ubuntu, open terminal (CTRL+ALT+T) and run below commands:
sudo apt install default-jre
sudo apt install libreoffice-java-common
- Once the installation is finished, close all instances of LibreOffice.
- Restart LibreOffice and perform the task which you were doing causing the error.
- You should not be receiving any more errors.
For other Linux distributions, download the related package (RPM, etc) from the above official Oracle download page.
If you have successfully installed the Java Runtime Environment, then go to
Tools -> Options -> Advanced again and you can see Java is listed (see below). Select the JRE and press OK.
If you are unable to find Java Runtime Environment after installing JRE, click on the Add button and browse-select the directory where Java is installed. For Windows 10, Java is installed typically in C:\Program Files\Java\jdk-***. OR C:\Program Files (x86)\Java\jre**** Select the jdk/jre folder and click Ok.
The above steps should solve the JRE error for LibreOffice. If you are still facing the error, drop a comment below with LibreOffice version, OS version.
- Don’t forget to let us know if this solves the problem for the benefit of others.
Be an expert on LibreOffice.
Small and quality tutorials. Delivered. Thrice a week.