In PHP, associative array is used to store data in key-value pairs. It is used to hold multiple key-value pairs in a single variable.
Create an Array
An associative array can be created using array() keyword. It can be initialized at the time of creation by specifying key-value pairs within the array() keyword and separated by comma(,) or it can be initialized later by specifying value using key.