Python has a method called len() that gives us the length of any composite object. To get the length of a string, just pass the string to the len() call.
If you want the size of the string in bytes, you can use the getsizeof() method from the sys module.
from sys import getsizeof getsizeof('Hello World!')
You can read more about it at sys.getsizeof()