How to check if Nginx is running on Windows?
To check if Nginx is running on Windows, you can follow these steps:
- Open the Command Prompt. You can open the Command Prompt window by pressing the Win+R keys, then typing “cmd” and pressing Enter.
- To check the status of Nginx, input the following command in the command prompt:
- Please check the status of nginx.
- This will display detailed information about the Nginx service.
- Check the output results; if the service status is “RUNNING” or “active”, it means Nginx is running. If the service status is “STOPPED” or “inactive”, it means Nginx is not started.
- Note: If you are using a self-compiled or manually installed Nginx, you may need to switch to the installation directory of Nginx in the command prompt (e.g. cd C:\nginx) before executing the above command.
Additionally, you can check if Nginx is running by accessing Nginx’s default port (usually 80). Simply enter http://localhost or http://127.0.0.1 in your browser, and if you can successfully access Nginx’s welcome page, then Nginx has been successfully launched. If you are unable to access it, it may be due to Nginx not being started or the port being occupied by something else.