This tutorial will cover the basics of making a solid shape into a transparent gradient, using the layer style options in Photoshop. For this example, I’m going to create a black to transparent gradient over an image, to create the effect of the image fading out to black. This effect is often used with a dark photograph fading to black on the background of a website, the reverse of this a lighter image fading to white is often used on the top of invitations and flyers.
Open up the picture that you wish to use in the background. The image that I’m using is from Wikimedia Commons and is copyright free if you wish to use the same image from this tutorial you can find it here.
Select the rectangle tool from the tool bar and select a bright colour from the foreground colour palette.
Draw with the rectangle tool over the picture. You will need to cover the bottom half of the picture with the rectangle. You can use the Direct Selection tool to move the individual points on the corners of the rectangle once you have drawn it. To select more than one point hold down Apple / Ctrl when selecting more points. If you then click and hold to drag the points, you can hold shift to keep the points in line.
With the new rectangle selected in the layers palette press the fx button at the bottom of the palette and choose Gradient Overlay from the drop down menu.
The gradient overlay panel will appear. Click and drag the panel to the side of the screen, so that you can see what effects the gradient overlay is creating on the canvas.
The gradient is already being applied in the direction that we need with white at the top and black at the bottom. If you need to change this you can change the angle on the panel by clicking in the direction you need within the circle. You can also change the percentage in angel degree in the box beside it. With 90 selected in the box the colours left to right in the gradient panel will go bottom to top. -90 they will change to top to bottom. With 0 they will display left to right and -180 right to left.
To change the black to white gradient to black to transparent, click on the gradient colour area.
This will show a new panel. The tags at the bottom of the gradient control the colour. The 2 at the top, the opacity.
Click on the opacity marker top right and change the opacity box to 0 and click ok.
As the name suggests, this will overlay the gradient over the top of the shape. The colour of the shape will now be showing through where the white section was. Click OK and exit the panel.
As the colour is fading from black to transparent it is also changing towards the white, so the black colour will lighten as the opacity reduces. To change this, click on the bottom left tag and change this colour to black.
The final step is to get rid of the initial shape colour. To change this, make sure the layer you are changing is highlighted in the layers palette and either use the slider or enter 0 in the Fill text box, top right on the layers palette.
To see the full effect of the image fading to black, extend the canvas downwards by going to Image > Canvas Size. The Canvas Size panel will appear over the canvas showing the current dimensions.
The Anchor diagram depicts which way the canvas will extend or shrink. To get it to extend downwards only, click on the top square in the middle. Enter a new value in the height field. I am working in pixels, so have changed the measurements to pixels. I want to extend the canvas down by 170 pixels, so have changed the height to 800. I also want the new bit of canvas to be coloured black and so have changed this in the drop down at the bottom.
You should now have an image similar to the one below
To cover slightly more of the photo with the transparent to black gradient you can select the original bright shape in the layers palette. Choose the direct selection tool and select the two top anchor points on the corners. (Hold shift whilst selecting the 2nd one to have them both selected at the same time.) Hold shift and drag them upwards. Hit the return key when you are happy with the new position to deselect it.
The final photo