Trimming the unwanted part of an image is what most Photoshop users do when they are finish with their design. This often happens when one is on a trial-and-error in determining the dimensions of a design document and ended up using only a small part. Trimming is different from cropping. Trimming an image is simply saying that you are removing the unwanted blank area in your design document. Take for example the image below:
The designer don’t know the exact dimensions he will be using so he decided to input 500 pixels by 400 pixels for his design document. He ended up not utilizing a large portion of the document. The solution is to either crop the document or simply trim it to make sure the maximum height and/or width of the image/s are on the edges of the design document. This will improve the size of the file (meaning the file size will be smaller), which will make it faster to load when you put it on a website.
To Trim the invisible part of an image or remove the transparent pixels, go to Image > Trim.
There are several different options which you can experiment but most often the “Transparent Pixels” radio button is chosen and all the checkboxes are checked.
After it is trimmed, the image will look like the one below: