View on Github

What is Jython?

Jython is a Java implementation of Python that combines expressive power with clarity. Jython is freely available for both commercial and non-commercial use and is distributed with source code under the PSF License v2. Jython is complementary to Java and is especially suited for the following tasks:

Here is an example of running Python code inside a simple Java application
import org.python.util.PythonInterpreter;

public class JythonHelloWorld {
  public static void main(String[] args) {
    try(PythonInterpreter pyInterp = new PythonInterpreter()) {
      pyInterp.exec("print('Hello Python World!')");
    }
  }
}
Here is an example of using Java from Python code
from java.lang import System # Java import

print('Running on Java version: ' + System.getProperty('java.version'))
print('Unix time from Java: ' + str(System.currentTimeMillis()))

Getting Started

Ready to get started? Head over to Downloads.

Or you could read a quick overview of features specific to Jython.

A more detailed introduction and reference can be found in the Jython Book.

Who uses Jython?

Jython is embedded in lots of projects. See some from MVNRepository