In the [[Java (programming language)|Java]] [[programming language]], [[source filesfile]]s (.java files) are compiled[[compile]]d into '''class files''' which have a .class extension. Since Java is a [[platform-independent]] language, [[source code]] is compiled into [[Byte-code|bytecode]], which it stores in a .class file. If a source file has more than one class, each class is compiled into a separate .class file. These .class files can be loaded by any [[Java Virtual Machine]] (JVM).
Since JVMs are available for many [[platform (computing)|platform]]s, the .class file compiled in one platform will execute in a JVM of another platform. This makes Java platform-independent.