Python decorators are functions that are used to transform other functions. The decorator can then take action, modify the arguments, halt execution or call the original function. @decorator_function def decorated(): pass We can configure Flask-Login to redirect unauthenticated users to a login page, return an HTTP .