To perform bootloader unlock on the Sony Xperia Z or ZL, you will need to download and install Fastboot files on your computer. The process is simple if you have a Windows 7 computer, but if you have a Windows 8, you will have to perform some extra steps in getting everything to work.
Download fastboot files from here and install them simply as you install any app on Windows 7. If you have a computer running Windows 8, follow these steps.
1. Press windowsKey + R and type/paste this
shutdown -o -r -t 0
2. This will restart your machine in the advanced startup menu and when it restarts choose "disable driver signing". Then, install the driver manually using the "have disk" option. when you reboot again the driver should be working.
3. Permanently turn off driver signing
bcdedit -set loadoptions DISABLE_INTEGRITY_CHECKS
bcdedit -set TESTSIGNING ON