PSD is a Adobe Photoshop Document extension file format. Photoshop allows you to flattern images and convert them into JPG, GIF or TIFF. Once the PSD file has been flattern is cannot be converted back to PSD and you will not able to work with the images layers.
JPG aka Joint Photographic Experts Group is a common file format for digital photos and other digital graphics. JPG files have the file extension .jpg or .jpeg. They are used for images taken with digital cameras, and widely used for photos and other graphics used on websites.
GIF aka Graphics Interchange Format is a bitmap image format. GIF files have the file extension .gif. GIF files are compressed using "lossless" compression meaning image quality is not sacrificed as file size reduces. GIF support transparency which allows you to place the gif over any color background or even photos and you won’t see a border or background in the image.
TIFF aka "Tagged Image File Format" is for storing bitmap images. It is commonly used by graphic artists and photographers.
PNG were developed to build upon the purpose of gifs. PNG incorporate low-resolution images that load quickly but also look great. Lossless means that they do not lose quality during editing. This is unlike jpegs, where they lose quality. PNG files tend to be larger than jpegs, because they contain more information and are lossless. PNG files do not support animation. For this purpose, a gif should be used.