You may use the split () function of the String class to split a string using a delimiter in Python. If a string or line contains more than one word, Python’s split () method returns a list of those words divided by the delimiter string. This function can produce a new string or a list of new strings. The list data type is used to return all of the substrings.