University of Iowa OSUM
Sign Up

Installing JRuby on Windows

Would you like the simplicity of a scripting language mixed with the power of a language with the ability to create a full GUI? Then JRuby is for you. JRuby is probably one of the most fun implementations of Ruby ever made. Not only does it bring the power, elegance, and simplicity of Ruby, but it features the abilities of Java as well!


  • Download a copy of the latest JRuby from the JRuby download page.
  • Unzip the file with your achive program. If you don't have one that works, download 7-Zip.
  • Copy the JRuby folder called jruby-1.1.5 directly to "C:/"
  • Install Java if you don't already have it. You'll want want of the latest versions which can be found at
  • Set environment variables on your system. Right click "My Computer" go to "Advanced" then "Environmental Variables". Create these:
    • JRUBY_HOME = C:/jruby-1.1.5
    • JAVA_HOME = C:/path/to/java (like C:/Program Files/Java/jre1.6.0_07)
  • Next you'll have to edit the PATH variable. Add ;C:\jruby-1.1.5\bin; to the end of that variable.
  • Setup Complete!

Next we'll be creating our first program. Starting is as simple as creating an empty file called 'program.rb'. Open the file with a text editor, such as Notepad or Wordpad, and insert the text below.

include Java
frame =
frame.getContentPane().add('Hello, World!'))

Now save the file and exit the text editor. Open the command prompt (Start->Run->'cmd'). Change your directory to wherever your file is. If you saved on your Desktop it's usually just 'cd Desktop'. Now type "jruby program.rb", and viola! Enjoy!


Resources Downloads


Link To Us