Returns true if the specified format name can be written
import java.io.File; import java.util.Iterator; import javax.imageio.ImageIO; public class Main { public static void main(String[] argv) throws Exception { boolean b; b = canWriteFormat("yourExtensionName"); b = canWriteFormat("gif"); b = canWriteFormat("giF"); } public static boolean canWriteFormat(String formatName) { Iterator iter = ImageIO.getImageWritersByFormatName(formatName); return iter.hasNext(); } }