The max algebra consists of the nonnegative real numbers equipped with two binary operations, maximization and multiplication. We characterize the invertible linear operators that preserve the set of commuting pairs of matrices over a subalgebra of max algebra.