PET plastic bottles start out in the form of plastic pellets made in whatever color the bottles will eventually be. Then the pellets are melted into a structure called a “preform”. The preform has threading at the top but no real bottle shape yet. Then the preforms are heated to a specific temperature to allow for melting into shape and are blown into a mold, a process known as blow-molding. The bottles are quickly cooled to maintain shape, then printed, filled, and capped, all by machines.
Watch this video to see the bottle manufacturing process in action: