Reverse String in Python To reverse the string in python use [::-1]. For example if you got a = 'This is a string!' you can do a = a[::-1]. This will reverse the string and store it in the same variable a.