The JRE is the Java runtime, allowing a machine to run a Java program.
You can run the java process and specify an entry point class (program) which has a "main" method. Execution starts in your main method and continues from there. This is usually referred to as a Java application.
The plugin is bundled with the JRE, and runs inside a browser, allowing Java code to run inside the browser process on the client.
The main entry point class must be written as an Applet when the plugin is used, but all the Java code it calls can be just regular Java.
Often it's more convenient to develop your application and run it as a Java application, then deploy it to your users as an applet. Most of the code can be identical.