The TO_DATE function in SQL is used to convert a character string (character literal) representing a date into an actual DATE data type, using a specified format mask. It does not convert date literals to dates or format dates into other character strings.