java.lang.NoClassDefFoundError

If you like a tip written by other Samebug users, mark is as helpful! Marks help our algorithm provide you better solutions and also help other users.
tip

Look if your classpath is correct, and check if the versions of your libraries match the version you described in your pom.xml

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

  • Why Is NoClassDefFoundError Displayed Here?
    via by Peter Mc Cormack,
  • Java: java.lang.NoClassDefFoundError
    via by Unknown author,
  • Java: Issue running from command line
    via Stack Overflow by Adam_G
    ,
  • Java Classpath Issues - will not run
    via Stack Overflow by Adam_G
    ,
    • java.lang.NoClassDefFoundError: TestPackage1 (wrong name: javahandcode/mainpackage/package1/TestPackage1) at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:791) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) at java.net.URLClassLoader.defineClass(URLClassLoader.java:449) at java.net.URLClassLoader.access$100(URLClassLoader.java:71) at java.net.URLClassLoader$1.run(URLClassLoader.java:361) at java.net.URLClassLoader$1.run(URLClassLoader.java:355) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:354) at java.lang.ClassLoader.loadClass(ClassLoader.java:423) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308) at java.lang.ClassLoader.loadClass(ClassLoader.java:356) at sun.launcher.LauncherHelper.checkAndLoadMain(LauncherHelper.java:480)

    Users with the same issue

    Unknown visitor
    Unknown visitor1 times, last one,
    Unknown visitor
    Unknown visitor1 times, last one,
    Unknown visitor
    Unknown visitor1 times, last one,
    Unknown visitor
    Unknown visitor1 times, last one,
    Unknown visitor
    Unknown visitor1 times, last one,
    150 more bugmates