Entropy is a statistics concept used to measure disorder in a sample.
It is applied to calculate the information gain of a decision tree’s split through node impurity, and can be described with the formula:
In a decision tree’s node, $P(X)$ is the number of times a given class has occurred in the node divided by the number of total examples $n$ in the node.
It is basically the probability of encountering that class in the node’s sample.
Still considering the same node sample and assuming the feature is binary, we will have the highest entropy when 50% of the examples come from one class and the other 50% comes from the other, while a node having 100% of examples coming from the same class will have $E = 0$.
Decision trees commonly use either entropy or gini index at each split.