17

I am looking for something like jsfiddle but for java, so that code snippets and classes can be shared and tested.

At the moment, I am using a combination of pastebin and compileonline.com. I would rather not sign up for a huge online compiler service, just a quick and dirty code sharing/testing platform, that provides unique URL's for my code snippets.

I have seen other people asking similar questions: https://stackoverflow.com/questions/15320286/is-there-online-compiler-for-java-like-jsfiddle

But there doesn't seem to be just the right tool. Anyone provide any pointers?

4
  • 8
    I think that this good question and it is not off-topic.
    – SaidbakR
    Aug 2, 2013 at 23:52
  • 1
    runnable.com is good, however, it is a little flaky at times.
    – Matt M.
    Oct 24, 2014 at 15:25
  • For offline there's jpad.io I'm considering making an online uploader, get in touch and we can discuss it. Feb 9, 2016 at 10:26
  • Other useful ones: (Mozilla-sponsored) webassembly.studio and (Google-sponsored) leetcode.com (but you need to select sandbox and explicitly use the "share" button). Also remoteinterview.io, but there's no file-management there. =\ Jun 13, 2018 at 17:06

1 Answer 1

26

I tried using http://ideone.com/. It supports a bunch of languages, including Java.

7
  • 1
    Agree with @Ostap. Just as a warning, be aware of the "private" check. Otherwise, your code will be available online, which could be a problem depending on what are you writing.
    – Daniel H.
    Jul 30, 2013 at 11:04
  • That looks really good, but I cant see any way of defining my own file names. I keep getting compilation errors due to namespace clashes between my classname and whatever filename they are using.
    – Husman
    Jul 30, 2013 at 12:16
  • I also need to log in to edit my code, so as an unregistered user, I have to copy/paste my code and for every bug/compile error I get, I have to create a new snippet with a unique URL, instead of just being able to edit it.
    – Husman
    Jul 30, 2013 at 12:18
  • 1
    You can press [Clone] button after your snippet in run. Then, all your code would be copy-pasted automatically. Jul 30, 2013 at 13:26
  • 2
    The best one I've found is runnable.com. IDE One was erroring out on me.
    – Leo
    Nov 13, 2014 at 20:02

Not the answer you're looking for? Browse other questions tagged or ask your own question.