mathplotlib save plot code example Example 1: save matplotlib figure plt.savefig('image.png') Example 2: save plot in python plt.savefig('books_read.png')