["python","flask"]
Flask at first run: Do not use the development server in a production environment

I installed the Flask plugin in PyCharm Community Edition and I just have this simple code in my flask app: from flask import Flask app = Flask(__name__) @app.route('/') def index(): return '<h1>Hello!</h1>' if __name__ == "__main__": app.run(debug=True) And I get this message: WARNING: This is a development server. Do not use it in a production deployment. Use a production WSGI server instead * Restarting with stat * Debugger is active! * Debugger PIN: 123-456-789 * Running on http://127.0.0.1:5000/ Why am I getting this error when I run Flask? A previous version of the message read "Do not use the development server in a production environment."
As of Flask 2.2, the development server always shows this warning, it is not possible to disable it. The development server is not intended for use in production. It is not designed to be particularly efficient, stable, or secure. Use a production WSGI server instead. See the deployment docs from Flask for more information. That warning is just a warning though, it's not an error preventing your app from running. If your app isn't working, there's something else wrong with your code. That warning applies to the development server, not Flask itself. The Flask framework is appropriate for any type of application and deployment.