Most of the time nowadays new reasonable priced laptops and tablets ship without an optical drive installed, which make it necessary to have a bootable USB stick to handle a lot of stuff like installing windows or booting to recovery mode.
A flash drive (4 GB for 32-bit, 8 GB for 64-bit).
Windows 8 or 8.1 ISO image, you can download from Here
Windows USB/DVD Download Tool, This tool allows you to create a copy of your Windows 7/8 ISO file on a USB flash drive or a DVD. as for your windows product key it can be embedded while building your ISO file, or it can just be saved on a paper to be used later on while installation is taking progress.
Building the bootable media
most of the steps are self explained as per pictures shown bellow:
loading your ISO file
Choose Media Type.
processing the media
Now that the you have a flash drive or USB based hard drive with the Windows 8 or Windows 8.1 installation files on it, you can use it to start the Windows 8 installation process on start-up boot.