The task is an individual unit of work for executors to run. It is an individual unit of physical execution (computation) that runs on a single machine for parts of your Spark application on a data. All tasks in a stage should be completed before moving on to another stage. A task can also be considered a computation in a stage on a partition in a given job attempt. A Task belongs to a single stage and operates on a single partition (a part of a Resilient Distributed Datasets (RDD) ). Tasks are spawned one by one for each stage and data partition.