 <p><a href="https://github.com/codegram/rack-webconsole" rel="nofollow">https://github.com/codegram/rack-webconsole</a></p> <p>Or you could simply pass the Ruby code to the server via post and call <a href="http://www.ruby-doc.org/core-1.9.2/Kernel.html#method-i-eval" rel="nofollow">eval</a> <code>eval(CODE)</code>.</p> <p>You should note that especially the second way is very insecure since it gives the executing code complete access to your system.</p> <p>If this really has to be done "<a href="http://ruby-doc.org/docs/ProgrammingRuby/taint.html" rel="nofollow">Locking Ruby in the Safe</a>" could help secure it.</p> <p>EDIT:</p> <p>For syntax highlighting take a look at <a href="http://codemirror.net/" rel="nofollow">Code Mirror</a> and <a href="http://ace.ajax.org/" rel="nofollow">ACE</a>. Both are decent source code editors with ruby support.</p>