You can also manually remove DataFrame from the cache usingunpersist()method in Spark/PySpark. unpersist() marks the DataFrame as non-persistent, and removes all blocks for it from memory and disk. unpersist(Boolean) with argument blocks until all blocks from the cache are deleted. Syntax // ...