Adding JavaFX to your Eclipse project

Sometimes you work with an raw Eclipse project without maven based dependency management for example. Maybe your builds still run with ant and all dependencies are configured in Eclipse. With a few tricks you can add JavaFX support to this projects on an easy way:

First of all you need the e(fx)clipse plugin for eclipse. You can find the plugin on the eclipse marketplace or you can download it here. The Plugin offers “JavaFX Library” as a new library type. You can add this library directly to your project to add the JavaFX dependency.


This adds JavaFX to your classpath but does not write an OS specific path in the project configuration. Any developer can now work with the project. The e(fx)clipse plugin handles the JavaFX dependency and finds the correct jar on your system. If the eclipse project depends on a JRE > 7u6 JavaFX is bundled in the JRE and e(fx)clipse finds it automatically.

Hendrik Ebbers

Hendrik Ebbers is the founder of Open Elements. He is a Java champion, a member of JSR expert groups and a JavaOne rockstar. Hendrik is a member of the Eclipse JakartaEE working group (WG) and the Eclipse Adoptium WG. In addition, Hendrik Ebbers is a member of the Board of Directors of the Eclipse Foundation.

Circle Circle

Open Source made right


Privacy Policy Cookie Policy Privacy Config Impressum